reactgrid icon indicating copy to clipboard operation
reactgrid copied to clipboard

Add Support for React 19

Open vessyb opened this issue 1 year ago • 4 comments

Hi ReactGrid Team,

Thank you for the great library—it has been an invaluable tool in my team's project. We are currently in the process of upgrading to React 19, but I’ve noticed that ReactGrid currently lists compatibility only with React 18 and earlier versions. I encounter dependency conflicts due to React 19 not being listed as a supported version.

Current Issue Here's an example of the error encountered during installation:

Could not resolve dependency:
npm error Found: [email protected]
npm error node_modules/react
npm error   react@"^19.0.0" from the root project

npm error peer react@"^16.13.1 || ^17.0.0 || ^18.2.0" from @silevis/[email protected]
npm error node_modules/@silevis/reactgrid
npm error   @silevis/reactgrid@"^4.1.12" from the root project

This makes it difficult to integrate ReactGrid into React 19 projects without using workarounds such as --force or --legacy-peer-deps, which are not ideal.

Request Could you please evaluate and add compatibility for React 19? If there are any known issues or blockers preventing ReactGrid from working with React 19, I’d appreciate it if you could share that information as well.

Additional Context React Version: 19.0.0 ReactGrid Version: 4.1.12 Environment: Node 22.7.0, npm 10.8.2 Steps to Reproduce: Install ReactGrid in a project using React 19.

Thank you for your time and consideration.

Best regards, Vesela

vessyb avatar Dec 11 '24 11:12 vessyb

Hey guys, what is the progress on this topic? V5 is still in alpha, so it seems unreasonable to use in production, wdyt?

vessyb avatar Feb 03 '25 08:02 vessyb

hi, any info regarding this one? the fix seems pretty easy - just add "|| ^19.0.0" in package json - would you accept a PR if I made one?

MateuszTrN avatar Mar 03 '25 08:03 MateuszTrN

Hi,

While we wait for the v5 release, I’ve forked the library and updated the peer dependencies to React/react- dom 19. It seems to be working—you can test it via npm:

npm install grid-react-19

How to use:

import { ReactGrid } from 'grid-react-19';
import 'grid-react-19/styles.css';

Everything else should work as described in the official docs, except for the import, which should come from 'grid-react-19'.

A sincere thanks to the ReactGrid team for your hard work!

mjakal avatar Mar 14 '25 10:03 mjakal

Hi,

While we wait for the v5 release, I’ve forked the library and updated the peer dependencies to React/react- dom 19. It seems to be working—you can test it via npm:

npm install grid-react-19

How to use:

import { ReactGrid } from 'grid-react-19';
import 'grid-react-19/styles.css';

Everything else should work as described in the official docs, except for the import, which should come from 'grid-react-19'.

A sincere thanks to the ReactGrid team for your hard work!

Hi I believe it's easier to add overrides or (if you use yarn) resolutions to package.json

...
"overrides": { 
  "@silevis/reactgrid": {
     "react": "^19.0.0",
     "react-dom": "^19.0.0"
   }
}
...```

MateuszTrN avatar Mar 19 '25 07:03 MateuszTrN