scniro / react-codemirror2

Codemirror integrated components for React
MIT License
1.65k stars 192 forks source link

Cannot upgrade react to 17 thanks to npm complaining that react-codemirror2 supports react 16 only #271

Closed vass-david closed 2 months ago

vass-david commented 2 years ago

Hi!

I can see that react version in this repo is correct (up to 17.x), but for some reason my npm complains that it's only up to 16.x. Any idea what went wrong? I've tried cleaning my npm cache, but it didn't help (I didn't expect it will anyway). Might it be that current version published in npm has an outdated package.json?

Thanks!

MikeHingley22 commented 2 years ago

The latest release (https://github.com/scniro/react-codemirror2/tree/7.1.0) has the following in the package.json file :

https://github.com/scniro/react-codemirror2/blob/cc3a47d0707b060bf1a1e42ccb258b9b7c0882fd/package.json#L56

I think the reason is that npm is reading the peer dependancy of 16.x and enforcing that. Latest version on npm seems to be 7.2.1 and that also has the same 16.x upper restriction.

AlexCriollo commented 2 years ago

The latest release (https://github.com/scniro/react-codemirror2/tree/7.1.0) has the following in the package.json file :

https://github.com/scniro/react-codemirror2/blob/cc3a47d0707b060bf1a1e42ccb258b9b7c0882fd/package.json#L56

I think the reason is that npm is reading the peer dependancy of 16.x and enforcing that. Latest version on npm seems to be 7.2.1 and that also has the same 16.x upper restriction.

i see that last release was back on 2020. Any word on when is the next one?

iiiusky commented 2 years ago

ping

ksathyanm commented 2 years ago

@elsigh @ihollander @fongandrew @anandsainath @scniro ping

vldmr1986 commented 2 years ago

Same for React 18

supun-io commented 2 years ago

Ended up copying index.tsx to the project :(

s100 commented 7 months ago

React 17 support was added under #224, which was published in react-codemirror2@7.3.0. Super work!