React Invariant Violation: Minified React error #130
The local operation of react is OK. After being packaged, an error is reported as follows:
When you encounter such a problem, usually there is a problem with import, either the name is written wrong, or case, or the imported component does not exist can not be found! Check the import of the problem area carefully and you will usually find the reason.
I encountered the reason is: in the same ts file exported more than one, and then imported elsewhere, the local operation are normal no problem, but after packaging may be due to sub-packaging or what, resulting in other places import place can not be found.
Solution: I wrote a separate file for the exported component, and after the other import references were modified, it was all good.
Read More:
- [Solved] React Error: ReactDOM.render is no longer supported in React 18.
- [Solved] react-router-dom Error: index.js:1 Warning: Functions are not valid as a React child.
- [Solved] React Dependency Error: Invalid tag name “^np.0.2“ of package “react@^np.0.2“: Tags may not have an
- React Error: history is undefined [How to Solve]
- React error boundary (What You Should Know & How to Solve)
- How to Solve React devtools plug-in Error
- [Solved] React Click the Event to Modify the State Value Error
- [Solved] React Startup Error at the First time :SyntaxError: Unexpected token
- [Solved] react-router-dom Error: <NavLink>activeClassName
- [Solved] vite2+vue3 jsx Error: React is not defined
- React: How to Solve Web3 import error
- [Solved] react-quill failed to install error: Could not resolve dependency
- [Solved] Error:The above error occurred in one of your React components & A component suspended while respondi
- React native android: How to Upload Formdata
- React project is packaged and set as required Error [How to Solve]
- [Solved] react Chrome Browser Error: Uncaught TypeError: Cannot read properties of undefined (reading ‘forEach‘)
- Anti card limited Drag Based on react draggable drag
- How to React page to achieve entry and exit animation
- [Solved] Failed to load config “react-app“ to extend from.
- [Solved] vue Project Error: react lazy eslint error Parsing error: Unexpected token import