ecs-dependency-injection
ecs-dependency-injection copied to clipboard
Conflicting peer dependencies: React ^16.8.1 || ^17 and React ^18
What happened ?
When trying to install the game dependencies, I ran into an error:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"^18.1.0" from the root project
npm ERR! peer react@"^18.1.0" from [email protected]
npm ERR! node_modules/react-dom
npm ERR! react-dom@"^18.1.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.8.0 || ^17" from [email protected]
npm ERR! node_modules/mobx-react-lite
npm ERR! mobx-react-lite@"^3.3.0" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: [email protected]
npm ERR! node_modules/react
npm ERR! peer react@"^16.8.0 || ^17" from [email protected]
npm ERR! node_modules/mobx-react-lite
npm ERR! mobx-react-lite@"^3.3.0" from the root project
Steps to reproduce
- Clone the game repository
- Run
npm install
Possible mitigation
Running npm install --force
seems to create a working build for React. Should we just ignore NPM warnings?
Thank you for your time putting these examples anyway.
@raaaahman Did you ever figure this out? I'm dealing with the exact same issue right now with Cypress instead of React.
@david-renner-dwg Yes, running npm install --force
still resulted in a working build for me.