morenoh149 / react-native-contacts

React Native Contacts
MIT License
1.64k stars 560 forks source link

Update Dependency #616

Closed Dror-Bar closed 3 years ago

Dror-Bar commented 3 years ago

I have the following versions: react-native: 0.64.0, react: 17.0.2 and react-native-contacts: 7.0.0

When running npm install, I get the following error message:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: [APP NAME]
npm ERR! Found: react@17.0.2
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@"17.0.1" from react-native@0.64.0
npm ERR! node_modules/react-native
npm ERR!   react-native@"0.64.0" from the root project
npm ERR!   peer react-native@">=0.64.0" from react-native-contacts@7.0.0
npm ERR!   node_modules/react-native-contacts
npm ERR!     react-native-contacts@"7.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.

It looks like you need to update your peer dependency.

morenoh149 commented 3 years ago

The issue is not with react-native-contacts.

See,

$ npm info react-native@0.64.0 peerDependencies                                                                                    
{ react: '17.0.1' } 

You have to downgrade react to 17.0.1, or upgrade react-native.