Closed corsin-ragettli closed 1 year ago
Currently, the onChange event of the FileUpload has the typing (files: Blob[]) => void. this is very confusing for new developers since they have no idea that actually, the onChange event provides further attributes:
onChange
(files: Blob[]) => void
{ "id": "string", "lastModified": "number", "lastModifiedDate": "Date", "name": "string", "size": "number", "type": "string" }
So my proposal is to change the typing of onChange to (files: File[]) => void
(files: File[]) => void
I have also now found out that the type is based on file and is enriched with id and optionally errorMessage.
Currently, the
onChange
event of the FileUpload has the typing(files: Blob[]) => void
. this is very confusing for new developers since they have no idea that actually, the onChange event provides further attributes:So my proposal is to change the typing of
onChange
to(files: File[]) => void