Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

TSC run fixes #212

Open
talal7860 opened this issue Jun 13, 2023 · 0 comments
Open

TSC run fixes #212

talal7860 opened this issue Jun 13, 2023 · 0 comments

Comments

@talal7860
Copy link

Hi! 馃憢

Firstly, thanks for your work on this project! 馃檪

Today I used patch-package to patch react-dropzone-uploader@2.11.0 for the project I'm working on.

Here is the diff that solved my problem:

diff --git a/node_modules/react-dropzone-uploader/dist/Dropzone.tsx b/node_modules/react-dropzone-uploader/dist/Dropzone.tsx
index da29a80..c6177ae 100644
--- a/node_modules/react-dropzone-uploader/dist/Dropzone.tsx
+++ b/node_modules/react-dropzone-uploader/dist/Dropzone.tsx
@@ -500,7 +500,7 @@ class Dropzone extends React.Component<IDropzoneProps, { active: boolean; dragge
     let params: IUploadParams | null = null
     try {
       params = await getUploadParams(fileWithMeta)
-    } catch (e) {
+    } catch (e: any) {
       console.error('Error Upload Params', e.stack)
     }
     if (params === null) return
@@ -630,7 +630,7 @@ class Dropzone extends React.Component<IDropzoneProps, { active: boolean; dragge
     const SubmitButton = SubmitButtonComponent || SubmitButtonDefault
     const Layout = LayoutComponent || LayoutDefault
 
-    let previews = null
+    let previews: any = null
     if (PreviewComponent !== null) {
       previews = files.map(f => {
         return (
diff --git a/node_modules/react-dropzone-uploader/dist/utils.ts b/node_modules/react-dropzone-uploader/dist/utils.ts
index 707918d..ebc6d89 100644
--- a/node_modules/react-dropzone-uploader/dist/utils.ts
+++ b/node_modules/react-dropzone-uploader/dist/utils.ts
@@ -94,7 +94,7 @@ export const mergeStyles = (
 export const getFilesFromEvent = (
   event: React.DragEvent<HTMLElement> | React.ChangeEvent<HTMLInputElement>,
 ): Array<File | DataTransferItem> => {
-  let items = null
+  let items: any = null
 
   if ('dataTransfer' in event) {
     const dt = event.dataTransfer

This issue body was partially generated by patch-package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant