Open
Description
In interface.d.ts
in these methods all the arguments are required:
onStart?: (file: RcFile) => void;
onError?: (error: Error, ret: object, file: RcFile) => void;
onSuccess?: (response: object, file: RcFile, xhr: object) => void;
onProgress?: (event: UploadProgressEvent, file: RcFile) => void;
beforeUpload?: (file: RcFile, FileList: RcFile[]) => BeforeUploadFileType | Promise<void | BeforeUploadFileType>;
But in my code I might be not interested in file
argument, for example. While all args are required I must still define them and get TS errors for defined and not used variables.
Could you please make these args optional like this:
onSuccess?: (response?: object, file?: RcFile, xhr?: object) => void;
Metadata
Metadata
Assignees
Labels
No labels