wwwaiser / react-js-pagination

http://vayser.github.io/react-js-pagination
Creative Commons Zero v1.0 Universal
353 stars 95 forks source link

Multiple React Instances #101

Open firzok opened 4 years ago

firzok commented 4 years ago

I think that React and React Dom should be in Peer Dependencies rather than Dependencies in package.json Because of this, npm ls react shows multiple instances of react when react-js-pagination is being used.

P.S: This is my first issue so please bear with me.

iron66 commented 4 years ago

I'm not sure but several React instances may cause troubles with react hooks

firzok commented 4 years ago

I'm not sure but several React instances may cause troubles with react hooks

Are you saying that the solution I suggested will cause this problem ?

pnicolli commented 4 years ago

@firzok It's the current situation that may cause problems with react-hooks. Your suggestion is helpful and should be addressed imho. See https://reactjs.org/warnings/invalid-hook-call-warning.html

HauresBogdan commented 3 years ago

npm ls react client@0.1.0 C:\Users\PC\Desktop\xxx\client +-- react@17.0.1 -- react-js-pagination@3.0.3 -- react@16.14.0

https://reactjs.org/warnings/invalid-hook-call-warning.html#duplicate-react