Import error after build
See original GitHub issueI’ve got an error while importing brand new built library.
It completely ok with importing your git version.
But I got an error after importing a library just right after built with webpack
command. Even if no any single change.
Uncaught (in promise) Error: addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component's `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).
at invariant (invariant.js:38)
at Object.addComponentAsRefTo (ReactOwner.js:68)
at attachRef (ReactRef.js:23)
at Object.ReactRef.attachRefs (ReactRef.js:42)
at ReactDOMComponent.attachRefs (ReactReconciler.js:23)
at CallbackQueue.notifyAll (CallbackQueue.js:76)
at ReactReconcileTransaction.close (ReactReconcileTransaction.js:80)
at ReactReconcileTransaction.closeAll (Transaction.js:206)
at ReactReconcileTransaction.perform (Transaction.js:153)
at ReactUpdatesFlushTransaction.perform (Transaction.js:140)
Do you have any idea what could be wrong?
Issue Analytics
- State:
- Created 7 years ago
- Comments:19 (17 by maintainers)
Top Results From Across the Web
Build failed to compile - Attempted import error - Stack Overflow
Attempted import error: 'decrypt' is not exported from '../../../../util/security' (imported as 'decrypt'). This error only appears when I try ...
Read more >How do I fix compile or build errors after importing a custom ...
Right-click on Assets -> Import Package -> Custom Package and select wvr_unity_sdk. ... you still might encounter a compile error or build failure....
Read more >module-not-found - Next.js
The module you're trying to import is not installed in your dependencies ... When importing a module from npm this module has to...
Read more >Project Import and Build errors in CCS
This error appears when the compiler include path specified in CCS involves a variable or macro and the variable is not resolved properly....
Read more >Fix ModuleNotFoundError (No Module Named CV2) Python ...
Fix ModuleNotFoundError (No Module Named CV2) Python Import Error (If ... No module named cv2 after trying to fix it with this video ......
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
no, because peer dependencies are bad 😛
@dylanvorster hi, I’m trying use babel-plugin-lodash to reduce the size of lodash chunk in my project. I can’t because react-diagrams embedded the whole package in distribution build… I’m using lodash v 4.17.4.
How can I resolve this scenario? (you says peer dependencies are bad, why?)