TypeError: Object(...) is not a function
See original GitHub issueHi
I upgraded my version (version 8) of React Dropzone and now my code is not working when I upgraded to version 10.
Uncaught TypeError: Object(...) is not a function
at useDropzone (:8080/main.js:85977)
at :8080/main.js:85645
at updateForwardRef (:8080/main.js:81088)
at beginWork (:8080/main.js:81883)
at performUnitOfWork (:8080/main.js:83897)
at workLoop (:8080/main.js:83936)
at HTMLUnknownElement.callCallback (:8080/main.js:68256)
at Object.invokeGuardedCallbackDev (:8080/main.js:68294)
at invokeGuardedCallback (:8080/main.js:68343)
at replayUnitOfWork (:8080/main.js:83350)
<Dropzone
accept="image/jpeg, image/png"
onDrop={this.onDrop.bind(this)}
maxSize={1000000}
getDataTransferItems={evt => fromEvent(evt)}>
{({ getRootProps, getInputProps, isDragActive }) => {
return (
<div
{...getRootProps()}
className={classNames('dropzone', { 'dropzone--isActive': isDragActive })}>
<input {...getInputProps()} />
{isDragActive ? (
<p>Drop files here...</p>
) : (
<p>
Try dropping some files here, or click to select files to upload. Only
jpeg and png images under 1mb will be accepted
</p>
)}
<ImagePreviewContainer item={this.props.item} />
</div>
);
}}
</Dropzone>
Issue Analytics
- State:
- Created 4 years ago
- Comments:6
Top Results From Across the Web
JavaScript "Uncaught TypeError: object is not a function ...
Try to have the function body before the function call in your JavaScript file.
Read more >TypeError: "x" is not a function - JavaScript - MDN Web Docs
The JavaScript exception "is not a function" occurs when there was an attempt to call a value from a function, but the value...
Read more >TypeError: Object(...) is not a function · Issue #14484 - GitHub
What is the current behaviour? I have created react functional component and implement state full logic using useState method but it throws an ......
Read more >How to Handle JavaScript Uncaught TypeError: “x” is Not a ...
The Javascript error TypeError: "x" is not a function occurs when there is an attempt to call a function on a value or...
Read more >JavaScript: Uncaught TypeError: n is not a function
This error occurs if you try to execute a function that is not initialized or is not initialized correctly. This means that the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok, I will check out react > 16.8 got to make sure it can work with IE 11(finding lots of stuff I am upgrading to newest versions just don’t work with IE 11)
You just need to upgrade to react > 16.8. There are no breaking changes in regards to react, so you should be fine.