react-file-input
react-file-input copied to clipboard
onChange not working ?
I'm able to click on the input and choose a file but then nothing happens, it seems onChange is never fired. Do you have any idea why ?
<FileInput
name="file"
accept=".jpg"
placeholder="Your image"
className="mdl-textfield__input"
onChange={this.handleChange.bind(this)}
/>
....
handleChange(event) {
this.setState({
'file': event.target.files[0]
})
};