We Are Going To Discuss About MUI installation doesn’t work with React 18. So lets Start this React Article.
MUI installation doesn’t work with React 18
- [Solved] MUI installation doesn't work with React 18
This is MUI's problem with the new version of react. They are working to release a new version of Material UI. in the meantime we can solve this problem by using –legacy-peer-deps.
- MUI installation doesn't work with React 18
This is MUI's problem with the new version of react. They are working to release a new version of Material UI. in the meantime we can solve this problem by using –legacy-peer-deps.
Solution 1
npm install @mui/material @emotion/react @emotion/styled --legacy-peer-deps
npm install @mui/icons-material --legacy-peer-deps
Github Issue : https://github.com/mui/material-ui/issues/32074
Original Author NavinKumarmMNK Of This Content
Solution 2
Install it with npm install @mui/material @emotion/react @emotion/styled --force
Original Author Arya Anish Of This Content
Solution 3
This is MUI’s problem with the new version of react. They are working to release a new version of Material UI. in the meantime we can solve this problem by using –legacy-peer-deps.
This is how: https://namespaceit.com/blog/mui-installation-doesnt-work-with-react-18
npm install @mui/material @emotion/react @emotion/styled --legacy-peer-deps
npm install @mui/icons-material --legacy-peer-deps
Original Author Milan Sachani Of This Content
Conclusion
So This is all About This Tutorial. Hope This Tutorial Helped You. Thank You.