mother / react-files

A file input (dropzone) management component for React

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to reset the file for onChange to work if same file is uploaded again

ajithv11 opened this issue · comments

commented

HI,

Onchange function is not triggering if I tried to upload same file again, See below code as an example

   <Files
    className='files-dropzone'
    onChange={(files)=>{
          console.log(files);// This is not logging if I upload same file again
    }}
    onError={(er,file)=>{

    }}
    accepts={['image/*']}
    multiple={false}
    maxFiles={1}
    maxFileSize={10000000}
    minFileSize={0}
    clickable
    >
    Drop files here or click to upload
  </Files>

Also Multiple= false not working

Thanks in advance

Unable to recreate this issue. What version of react-files are you using?