Dependency Issue, React DnD Beautiful [duplicate] - node.js

This question already has answers here:
Unable to install react-beautiful-dnd package
(2 answers)
Closed 1 year ago.
I'm trying to install the following package, which is well known.
However, I'm a little confused as to how to diagnose this issue. I'd like to use this package as it's a core concept of my site, drag and drop.
Is this saying I need react #16.14.0? How would I go about bumping the entire project up correctly? Will this cause issues with other packages?
I am quite new to React and specifically this concept of tree dependencies? I also know my packages may be messed up, and if I need to, I'm happy to try resolve with tips.
npm i react-beautiful-dnd
However I get these errors:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: new#0.1.0
npm ERR! Found: react#16.8.0
npm ERR! node_modules/react
npm ERR! peer react#">=16.8.0" from #emotion/react#11.7.0
npm ERR! node_modules/#emotion/react
npm ERR! peer #emotion/react#"^11.0.0-rc.0" from #emotion/styled#11.6.0
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.2.4
npm ERR! node_modules/#mui/icons-material
npm ERR! 1 more (the root project)
npm ERR! 3 more (#mui/styled-engine, #mui/system, the root project)
npm ERR! peerOptional #emotion/react#"^11.5.0" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.2.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"^5.2.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! 3 more (#mui/styled-engine, #mui/system, the root project)
npm ERR! peer react#">=16.8.0" from #emotion/styled#11.6.0
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.2.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"^5.2.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/styled-engine#5.2.0
npm ERR! node_modules/#mui/styled-engine
npm ERR! #mui/styled-engine#"^5.2.0" from #mui/system#5.2.3
npm ERR! node_modules/#mui/system
npm ERR! #mui/system#"^5.2.3" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! 2 more (#mui/system, the root project)
npm ERR! 22 more (#material-ui/core, #material-ui/icons, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! react-beautiful-dnd#"*" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: react#16.14.0
npm ERR! node_modules/react
npm ERR! peer react#"^16.8.5 || ^17.0.0" from react-beautiful-dnd#13.1.0
npm ERR! node_modules/react-beautiful-dnd
npm ERR! react-beautiful-dnd#"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
It's worth noting my package.json looks:
{
"name": "new",
"version": "0.1.0",
"private": true,
"dependencies": {
"#emotion/react": "^11.7.0",
"#emotion/styled": "^11.6.0",
"#fontsource/roboto": "^4.5.1",
"#material-ui/icons": "^4.11.2",
"#mui/icons-material": "^5.2.4",
"#mui/material": "^5.2.3",
"#testing-library/jest-dom": "^5.11.4",
"#testing-library/react": "^11.1.0",
"#testing-library/user-event": "^12.1.10",
"framer-motion": "^4.1.17",
"gsap": "^3.9.1",
"material-ui-search-bar": "^1.0.0",
"react": "^16.8.0",
"react-dom": "^16.8.0",
"react-draggable": "^4.4.4",
"react-intersection-observer": "^8.33.1",
"react-scripts": "4.0.3",
"react-typewriter-effect": "^1.1.0",
"styled-components": "^5.3.3",
"typewriter-effect": "^2.18.2",
"web-vitals": "^1.0.1"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
Is this saying I need react #16.14.0? How would I go about bumping the entire project up correctly? Will this cause issues with other packages?

Maybe your problem could be solved by removing the node_modules folder and running npm -g install npm, like this tutorial suggest: Unable to install react-beautiful-dnd package

Related

react#18.2.0 Could not resolve dependency

I am new in React and trying to build new website using react and material ui, However, I am getting below error when trying to update/install packages from package.json
My npm version : 8.19.3
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: react-chartjs-2#3.0.4
npm ERR! Found: react#18.2.0
npm ERR! node_modules/react
npm ERR! peer react#">=16.8.0" from #emotion/react#11.9.3
npm ERR! node_modules/#emotion/react
npm ERR! peer #emotion/react#"^11.0.0-rc.0" from #emotion/styled#11.9.3
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.8.6
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! 1 more (the root project)
npm ERR! 4 more (#mui/styled-engine, #mui/system, #mui/styled-engine, the root project)
npm ERR! peerOptional #emotion/react#"^11.5.0" from #mui/material#5.8.6
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"5.8.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! 4 more (#mui/styled-engine, #mui/system, #mui/styled-engine, the root project)
npm ERR! peer react#">=16.8.0" from #emotion/styled#11.9.3
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.8.6
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"5.8.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/styled-engine#5.8.0
npm ERR! node_modules/#mui/styled-engine
npm ERR! #mui/styled-engine#"5.8.0" from the root project
npm ERR! 3 more (#mui/system, #mui/styled-engine, the root project)
npm ERR! 18 more (#mui/base, #mui/icons-material, #mui/material, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^16.8.0 || ^17.0.0" from react-chartjs-2#3.0.4
npm ERR! node_modules/react-chartjs-2
npm ERR! react-chartjs-2#"3.0.4" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: react#17.0.2
npm ERR! node_modules/react
npm ERR! peer react#"^16.8.0 || ^17.0.0" from react-chartjs-2#3.0.4
npm ERR! node_modules/react-chartjs-2
npm ERR! react-chartjs-2#"3.0.4" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See C:\Users\Admin\AppData\Local\npm-cache\eresolve-report.txt for a full report. </pre> My Package.json
{
"name": "react-ui",
"version": "4.0.0",
"author": "",
"license": "",
"description": "",
"engines": {
"node": "14 || 15 || 16",
"npm": ">=6"
},
"dependencies": {
"#emotion/cache": "11.9.3",
"#emotion/react": "11.9.3",
"#emotion/styled": "11.9.3",
"#mui/icons-material": "5.8.4",
"#mui/material": "5.8.6",
"#mui/styled-engine": "5.8.0",
"#testing-library/jest-dom": "5.16.4",
"#testing-library/react": "13.3.0",
"#testing-library/user-event": "14.2.1",
"chart.js": "3.4.1",
"chroma-js": "2.4.2",
"prop-types": "^15.8.1",
"react": "18.2.0",
"react-chartjs-2": "3.0.4",
"react-countup": "6.3.0",
"react-dom": "18.2.0",
"react-flatpickr": "3.10.13",
"react-router": "^6.8.0",
"react-router-dom": "6.3.0",
"react-scripts": "5.0.1",
"socket.io": "^4.5.4",
"socket.io-client": "^4.5.4",
"stylis": "4.1.1",
"stylis-plugin-rtl": "2.1.1",
"uuid": "8.3.2",
"web-vitals": "2.1.4"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject",
"install:clean": "rm -rf node_modules/ && rm -rf package-lock.json && npm install && npm
start",
"install:peer-deps": "npm install --legacy-peer-deps"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"eslint": "8.18.0",
"eslint-config-prettier": "8.5.0",
"eslint-plugin-import": "2.26.0",
"eslint-plugin-prettier": "4.2.1",
"eslint-plugin-react": "7.30.1",
"eslint-plugin-react-hooks": "4.6.0",
"prettier": "2.7.1"
}
}
`

how to fix npm install for react native

i am using react native to build a app every time I try to install a npm package i have to use --force, or --legacy-peer-deps to make it install else i get error so i thought it is because of version of react in my pakgage.json so i dissided to downgrade my react to 17.0.1 from 18.1.0 and i deleted my pakage.lock.json and node modules and i tried npm i then I am getting this error i want to get a clean installation for react native
npm i
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: sukprsavam#0.0.1
npm ERR! Found: react#17.0.1
npm ERR! node_modules/react
npm ERR! react#"17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react-native#"^0.0.0-0 || 0.60 - 0.71 || 1000.0.0" from #react-native-async-storage/async-storage#1.17.11
npm ERR! node_modules/#react-native-async-storage/async-storage
npm ERR! #react-native-async-storage/async-storage#"^1.17.11" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! peer react#"18.1.0" from react-native#0.70.6
npm ERR! node_modules/react-native
npm ERR! react-native#"0.70.6" from the root project
npm ERR! peer react-native#"^0.0.0-0 || 0.60 - 0.71 || 1000.0.0" from #react-native-async-storage/async-storage#1.17.11
npm ERR! node_modules/#react-native-async-storage/async-storage
npm ERR! #react-native-async-storage/async-storage#"^1.17.11" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See C:\Users\vivek\AppData\Local\npm-cache\eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\vivek\AppData\Local\npm-cache\_logs\2023-01-04T06_02_30_598Z-debug-0.log
"name": "newapp",
"version": "1.0.0",
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web"
},
"dependencies": {
"#react-navigation/native": "^6.1.1",
"#react-navigation/native-stack": "^6.9.7",
"axios": "^1.2.2",
"expo": "~47.0.9",
"expo-status-bar": "~1.4.2",
"moment": "^2.29.4",
"react": "18.1.0",
"react-client-session": "^0.0.8",
"react-native": "0.70.5",
"react-native-network-logger": "^1.13.0",
"react-native-paper": "^5.1.2",
"react-native-safe-area-context": "4.4.1",
"react-native-screens": "~3.18.0",
"react-navigation": "^4.4.4"
},
"devDependencies": {
"#babel/core": "^7.12.9"
},
"private": true
}

How to solve upstream dependency conflict (react version 17 didn't work because dependency conflict)

I installed react version 18 but kakao-map-api was not install in 18 version, so I downgrade to react 17.2.0 but it did not work.
I read the error line but I can't understand at all. Do I have to fix all in script tag from package.json file?
For example, testing-library version, emotion/react version? How can I know the version which is fit in react 17? I forcely tried command 'npm install
react-kakao-maps-sdk' in cmd and of course it didn't work for same reason.
I tried downgrade 17 version on command line, and also in package.json but still not work.
Complying from command line, 'fix the upstream dependency conflict', how can I know which version and which library can solve dependency problem?
Here is the error line if I commanded 'npm install react-kakao-maps-sdk'.
npm install react-kakao-maps-sdk
npm WARN config global --global, --local are deprecated. Use --location=global instead.
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: #testing-library/react#13.3.0
npm ERR! Found: react#17.0.2
npm ERR! node_modules/react
npm ERR! peer react#">=16.8.0" from #emotion/react#11.9.3
npm ERR! node_modules/#emotion/react
npm ERR! peer #emotion/react#"^11.0.0-rc.0" from #emotion/styled#11.9.3
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.9.0
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! 1 more (the
root project)
npm ERR! 3 more (#mui/styled-engine, #mui/system, the root project)
npm ERR! peerOptional #emotion/react#"^11.5.0" from #mui/material#5.9.0
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"^5.8.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! 3 more (#mui/styled-engine, #mui/system, the
root project)
npm ERR! peer react#">=16.8.0" from #emotion/styled#11.9.3
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.9.0
npm ERR! node_modules/#mui/material
npm ERR! peer #mui/material#"^5.0.0" from #mui/icons-material#5.8.4
npm ERR! node_modules/#mui/icons-material
npm ERR! #mui/icons-material#"^5.8.4" from the root project
npm ERR! 1 more (the root project)
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/styled-engine#5.8.7
npm ERR! node_modules/#mui/styled-engine
npm ERR! #mui/styled-engine#"^5.8.7" from #mui/system#5.9.0
npm ERR! node_modules/#mui/system
npm ERR! #mui/system#"^5.9.0" from #mui/material#5.9.0
npm ERR! node_modules/#mui/material
npm ERR! 2 more (#mui/system, the root project)
npm ERR! 12 more (#mui/base, #mui/icons-material, #mui/material, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^18.0.0" from #testing-library/react#13.3.0
npm ERR! node_modules/#testing-library/react
npm ERR! #testing-library/react#"^13.3.0" from the root
project
npm ERR!
npm ERR! Conflicting peer dependency: react#18.2.0
npm ERR! node_modules/react
npm ERR! peer react#"^18.0.0" from #testing-library/react#13.3.0
npm ERR! node_modules/#testing-library/react
npm ERR! #testing-library/react#"^13.3.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See C:\Users\USER\AppData\Local\npm-cache\eresolve-report.txt for a full report.
And here is my package.json file.
{
"name": "songpider-traveling-app",
"version": "0.1.0",
"private": true,
"dependencies": {
"#emotion/react": "^11.9.3",
"#emotion/styled": "^11.9.3",
"#mui/icons-material": "^5.8.4",
"#mui/material": "^5.9.0",
"#testing-library/jest-dom": "^5.16.4",
"#testing-library/react": "^13.3.0",
"#testing-library/user-event": "^13.5.0",
"npm": "^8.15.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-router": "^6.3.0",
"react-scripts": "^2.1.3",
"reactstrap": "^9.1.2",
"web-vitals": "^2.1.4"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
enter code here
enter code here
npm install --legacy-peer-deps

NPM Dependency Resolution Conflicts

When I run node install I get the following output:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: google-map-react#2.1.10
npm ERR! Found: react#18.1.0
npm ERR! node_modules/react
npm ERR! react#"^18.1.0" from the root project
npm ERR! peer react#">=16.3" from #deck.gl/react#8.7.8
npm ERR! node_modules/#deck.gl/react
npm ERR! #deck.gl/react#"8.7.8" from deck.gl#8.7.8
npm ERR! node_modules/deck.gl
npm ERR! deck.gl#"^8.7.8" from the root project
npm ERR! 15 more (#emotion/react, #emotion/styled, #mui/base, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^16.0.0 || ^17.0.0" from google-map-react#2.1.10
npm ERR! node_modules/google-map-react
npm ERR! google-map-react#"^2.1.10" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: react#17.0.2
npm ERR! node_modules/react
npm ERR! peer react#"^16.0.0 || ^17.0.0" from google-map-react#2.1.10
npm ERR! node_modules/google-map-react
npm ERR! google-map-react#"^2.1.10" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
and here is my package.json file:
{
"name": "frontend",
"version": "0.1.0",
"private": true,
"dependencies": {
"#emotion/react": "^11.9.0",
"#emotion/styled": "^11.8.1",
"#mui/icons-material": "^5.6.2",
"#mui/material": "^5.6.3",
"deck.gl": "^8.7.8",
"react": "^18.1.0",
"react-dom": "^18.1.0",
"react-router": "^6.3.0",
"react-router-dom": "^5.1.2",
"react-scripts": "5.0.1",
"react-transition-group": "^4.3.0"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
I have tried already npm install --legacy-peer-deps and npm install --force none of which changed the error message. I also tried npm install --legacy-peer-deps --save google-maps-react to see if I had to perform this individually for each package, no luck. I am aware that this error is relatively common, and it has something to do with the npm version and the dreaded breaking changes.
Does anyone know any other steps I can take?
I resolved the issue by running npm install --legacy-peer-deps after going from my pc's version of node 18.0.0 to the latest 16 LTS.
Found: react#18.1.0
npm ERR! peer react#"^16.8.0 || ^17.0.0"
npm config set legacy-peer-deps true
npm install --save --legacy-peer-deps
npm install --force
I resolved it by running the below instructions.
npm config set legacy-peer-deps true
This command sets the legacy-peer-deps configuration option to true. This means that any legacy peer dependencies that are defined in the package.json file will be installed when you run the NPM install command.
npm install --save --legacy-peer-deps
This command installs the dependencies defined in the package.json file, including any legacy peer dependencies that are defined. The --save option tells NPM to add the installed dependencies to the dependencies section in the package.json file.
npm install --force
This command forces NPM to reinstall all the dependencies defined in the package.json file, even if they are already installed. The --force option can be useful if you have made changes to the package.json file and need to reinstall the dependencies to reflect those changes.

Conflicting Packages in React Project

Just looking to resolve this. I'm quite sure it'll be an easy solve for people used to node packaging errors.
I'm trying to resolve: npm install #material-ui/icons
When using, I receive the following:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: #mui/material#5.2.3
npm ERR! Found: react#16.14.0
npm ERR! node_modules/react
npm ERR! react#"^16.13.0" from the root project
npm ERR! peer react#">=16.8.0" from #emotion/react#11.7.0
npm ERR! node_modules/#emotion/react
npm ERR! peer #emotion/react#"^11.0.0-rc.0" from #emotion/styled#11.6.0
npm ERR! node_modules/#emotion/styled
npm ERR! peerOptional #emotion/styled#"^11.3.0" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! #mui/material#"^5.2.3" from the root project
npm ERR! 3 more (#mui/styled-engine, #mui/system, the root project)
npm ERR! peerOptional #emotion/react#"^11.5.0" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! #mui/material#"^5.2.3" from the root project
npm ERR! 3 more (#mui/styled-engine, #mui/system, the root project)
npm ERR! 11 more (#emotion/styled, #testing-library/react, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"^17.0.2" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! #mui/material#"^5.2.3" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: react#17.0.2
npm ERR! node_modules/react
npm ERR! peer react#"^17.0.2" from #mui/material#5.2.3
npm ERR! node_modules/#mui/material
npm ERR! #mui/material#"^5.2.3" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See C:\Users\Nathan\AppData\Local\npm-cache\eresolve-report.txt for a full report.
I've worked back to my yarn.lock package, which has the following. One note, I am not using yarn.
"react#*", "react#^17.0.2", "react#>= 16", "react#>= 16.8.0", "react#>=16.6.0", "react#>=16.8.0", "react#17.0.2":
"integrity" "sha512-gnhPt75i/dq/z3/6q/0asP78D0u592D5L1pd7M8P+dck6Fu/jJeL6iVVK23fptSUZj8Vjf++7wXA8UNclGQcbA=="
"resolved" "https://registry.npmjs.org/react/-/react-17.0.2.tgz"
"version" "17.0.2"
dependencies:
"loose-envify" "^1.1.0"
"object-assign" "^4.1.1"
It's likely also worth noting my package.json is:
{
"name": "new",
"version": "0.1.0",
"private": true,
"dependencies": {
"#emotion/react": "^11.7.0",
"#emotion/styled": "^11.6.0",
"#fontsource/roboto": "^4.5.1",
"#mui/material": "^5.2.3",
"#testing-library/jest-dom": "^5.11.4",
"#testing-library/react": "^11.1.0",
"#testing-library/user-event": "^12.1.10",
"react": "^16.13.0",
"react-dom": "^16.13.0",
"react-scripts": "4.0.3",
"styled-components": "^5.3.3",
"web-vitals": "^1.0.1"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}

Resources