nkbt / react-debounce-input

React component that renders Input with debounced onChange
MIT License
450 stars 61 forks source link

React 17.x support please #137

Closed cgmack closed 3 years ago

cgmack commented 3 years ago

When installing react-debounce-input in my react 17.0.1 project, I get the following error. It appears that react-debounce-input@3.2.3 is limited to react@"^15.3.0 || ^16.0.0". Is there something preventing 17.x support? Is there a timeline for this support? Thank you.

$ npm i --save react-debounce-input
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: frontend@0.1.0
npm ERR! Found: react@17.0.2
npm ERR! node_modules/react
npm ERR!   react@"^17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^15.3.0 || ^16.0.0" from react-debounce-input@3.2.3
npm ERR! node_modules/react-debounce-input
npm ERR!   react-debounce-input@"*" 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.
nkbt commented 3 years ago

It should work with any modern React version. Just need to add 17 to peer deps

Meanwhile you can use --force, or --legacy-peer-deps to get it installed.

cgmack commented 3 years ago

Great. Thanks for confirming.

Berend-Kalberg commented 3 years ago

Second this. Has not been fixed yet. Came here to confirm if it still works because its a great tool.

iMoses-Apiiro commented 3 years ago

It should work with any modern React version. Just need to add 17 to peer deps

@nkbt Can you please add it and push a new patch version?

jschaffer-edr commented 3 years ago

Added PR https://github.com/nkbt/react-debounce-input/pull/142

char0n commented 3 years ago

Cool, any ETA for a release?

nkbt commented 3 years ago
Screen Shot 2021-07-20 at 12 09 54