Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Peer Dependency conflict in React 17 project and npm7 #214

Open
sterlingwalsh opened this issue Jun 8, 2021 · 3 comments
Open

Peer Dependency conflict in React 17 project and npm7 #214

sterlingwalsh opened this issue Jun 8, 2021 · 3 comments

Comments

@sterlingwalsh
Copy link

npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR!   react@"^17.0.2" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.9.0" from [email protected]
npm ERR! node_modules/react-sortablejs
npm ERR!   react-sortablejs@"^6.0.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.

This is due to the updates to npm in NPM 7 https://github.blog/2021-02-02-npm-7-is-now-generally-available/#peer-dependencies and is causing an npm install to fail under npm 7 while working under npm 6

I suspect updating the react and react-dom peer dependencies to "^16.9.0 - 17" should suffice

@sterlingwalsh sterlingwalsh changed the title Peer Dependency conflict in React 17 project Peer Dependency conflict in React 17 project and npm7 Jun 8, 2021
@FritzJo
Copy link

FritzJo commented Jun 23, 2021

Until this issue is fixed, installing sortablejs with the --force flag worked for me

npm install --save react-sortablejs sortablejs --force

@bogdancss
Copy link

any updates on this?

@rivu007
Copy link

rivu007 commented Apr 21, 2022

it would be nice if you guys could prioritize this issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants