react-strict-dom
react-strict-dom copied to clipboard
React 19, broken peerDependencies, cannot npm i react-strict-dom
Describe the issue
In short, you cannot simply install this package because react-native@>=0.75.2 currently points to 0.79.1 which peerDependencies react@^19.0.0, but this package peerDependencies React 18.
$ npm i react-strict-dom
npm error code ERESOLVE
npm error ERESOLVE unable to resolve dependency tree
npm error
npm error While resolving: [email protected]
npm error Found: [email protected]
npm error node_modules/react
npm error peer react@"^18.2.0" from [email protected]
npm error node_modules/react-strict-dom
npm error react-strict-dom@"*" from the root project
npm error peer react@"^18.3.1" from [email protected]
npm error node_modules/react-dom
npm error peer react-dom@"^18.2.0" from [email protected]
npm error node_modules/react-strict-dom
npm error react-strict-dom@"*" from the root project
npm error
npm error Could not resolve dependency:
npm error peer react@"^19.0.0" from [email protected]
npm error node_modules/react-native
npm error peer react-native@">=0.75.2" from [email protected]
npm error node_modules/react-strict-dom
npm error react-strict-dom@"*" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
Expected behavior
npm i react-strict-dom into an empty directory should Just-Work™.
Steps to reproduce
Node v22.14.0, npm 10.9.2, react-strict-dom 0.0.34.
npm i react-strict-dom
Test case
No response
Additional comments
Can the peerDependencies simply be updated to include React 19, and a new version published?
"peerDependencies": {
"react": "^18.2.0 || ^19.1.0",
"react-dom": "^18.2.0 || ^19.1.0",
"react-native": ">=0.75.2"
},
I haven't noticed any issues when forcing it to use React 19 via --legacy-peer-deps. Additionally react-native requires React 19 and Expo SDK 53 with React 19 is fast approaching the end of an ~2 week beta.