Support React 17.x
mneira10 opened this issue · comments
Hey! Thanks for such a cool library!
Currently, react-carousel
supports up to version 16.8.0
of react. It would be awesome if it would support 17.x
!
May I ask what issues you ran into?
If your project uses React 17, an npm install
will fail and only succeed with the --legacy-peer-deps
flag as follows:
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@"^16.8.0" from @brainhubeu/react-carousel@2.0.4
npm ERR! node_modules/@brainhubeu/react-carousel
npm ERR! @brainhubeu/react-carousel@"^2.0.4" from the root project
Luckily it works out of the box in React 17. Just annoying that you have to use this dangerous flag for installing it.
If your project uses React 17, an
npm install
will fail and only succeed with the--legacy-peer-deps
flag as follows: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@"^16.8.0" from @brainhubeu/react-carousel@2.0.4 npm ERR! node_modules/@brainhubeu/react-carousel npm ERR! @brainhubeu/react-carousel@"^2.0.4" from the root project
Luckily it works out of the box in React 17. Just annoying that you have to use this dangerous flag for installing it.
I'm facing the same problem :(
If your project uses React 17, an
npm install
will fail and only succeed with the--legacy-peer-deps
flag as follows: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@"^16.8.0" from @brainhubeu/react-carousel@2.0.4 npm ERR! node_modules/@brainhubeu/react-carousel npm ERR! @brainhubeu/react-carousel@"^2.0.4" from the root project
Luckily it works out of the box in React 17. Just annoying that you have to use this dangerous flag for installing it.
Good to know! It would be better for the peace of mind to install it without the dangerous flag though
If your project uses React 17, an
npm install
will fail and only succeed with the--legacy-peer-deps
flag as follows: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@"^16.8.0" from @brainhubeu/react-carousel@2.0.4 npm ERR! node_modules/@brainhubeu/react-carousel npm ERR! @brainhubeu/react-carousel@"^2.0.4" from the root project
Luckily it works out of the box in React 17. Just annoying that you have to use this dangerous flag for installing it.
Same issue here... Please update the dependency configuration.
Would be great if react 17 is supported. please update the dependencies.
Please support react 17.x
Please support react 17.x
yes, please do
please
Here's the patch for React 17-18
https://www.npmjs.com/package/@itseasy21/react-elastic-carousel
and update your imports.