Detaysoft / react-chat-elements

Reactjs chat elements chat UI, react chat components
MIT License
1.22k stars 218 forks source link

Could not resolve dependency error #187

Closed PisOliver closed 1 year ago

PisOliver commented 1 year ago

When I'm trying to install I get dependency resolve error:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: react-chat-elements@12.0.7
npm ERR! Found: react@18.2.0
npm ERR! node_modules/react
npm ERR!   react@"^18.2.0" from the root project
npm ERR!   peer react@"^18.0.0" from @testing-library/react@13.4.0
npm ERR!   node_modules/@testing-library/react
npm ERR!     @testing-library/react@"^13.4.0" from the root project
npm ERR!   5 more (react-dom, react-icons, react-router, react-router-dom, react-scripts)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^17.0.2" from react-chat-elements@12.0.7
npm ERR! node_modules/react-chat-elements
npm ERR!   react-chat-elements@"^12.0.7" 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 react-chat-elements@12.0.7
npm ERR!   node_modules/react-chat-elements
npm ERR!     react-chat-elements@"^12.0.7" 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
royibernthal commented 1 year ago

Joining the issue. Any plan on supporting React 18 anytime soon?

kursatsmsek commented 1 year ago

@PisOliver, seems you used npm install command. a better way is to use yarn or pnpm instead.

kursatsmsek commented 1 year ago

Joining the issue. Any plan on supporting React 18 anytime soon?

@royibernthal

Supporting React 18 is important for our package so it's in our plans. However, we don't have a study for this at the moment.