jsonkao / react-scrollama

Simple scrollytelling with the IntersectionObserver in React.
https://jsonkao.github.io/react-scrollama
MIT License
390 stars 30 forks source link

Update peerDependencies - allow React 17 and 18 #67

Closed jkjustjoshing closed 2 years ago

jkjustjoshing commented 2 years ago

Right now, the versions of react and react-dom required are ^16.8.0. However, this library should work fine with React 17 and React 18 (both of which are allowed in the react-intersection-observer dependency.

NPM v8 is enforcing peerDependencies more strictly than previous versions, so trying to install this on a React 17 project errors. I don't think there's anything in the library that would preclude it from working on newer versions of React. Can we add those versions to this package's peer dependencies?

jsonkao commented 2 years ago

Thanks for letting me know! Yes, this should be fine. Wanna submit a PR?

RSS1102 commented 2 years ago

react and react-dom: ^18.xx now,may be should update it. v_v

jsonkao commented 2 years ago

Yup #90 adds React 18 - just published a new release of the library - 2.3.2. Thanks for pointing this out yall!