Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[graphiql] Update graphiql-react to support React 19 #3850

Open
Achder opened this issue Jan 13, 2025 · 2 comments
Open

[graphiql] Update graphiql-react to support React 19 #3850

Achder opened this issue Jan 13, 2025 · 2 comments

Comments

@Achder
Copy link

Achder commented Jan 13, 2025

Right now graphiql-react only supports React 16, 17 and 18.
Since React 19 has now officially released graphiql could add support for React 19.

See peer dependencies here:
https://github.com/graphql/graphiql/blob/main/packages/graphiql-react/package.json

@mmswi
Copy link

mmswi commented Jan 20, 2025

Yes, we need this update.

Updated to next15 which involved react19 and I'm getting this error

`nx run archbee-ui:build:production

▲ Next.js 15.1.5

  • Experiments (use with caution):
    · clientTraceMetadata

Skipping linting
Checking validity of types ...
Creating an optimized production build ...
Failed to compile.

../../node_modules/@graphiql/react/node_modules/@headlessui/react/dist/utils/stable-collection.js
Attempted import error: '__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED' is not exported from 'react' (imported as 'r').

Import trace for requested module:
../../node_modules/@graphiql/react/node_modules/@headlessui/react/dist/utils/stable-collection.js
../../node_modules/@graphiql/react/node_modules/@headlessui/react/dist/components/tabs/tabs.js
../../node_modules/@graphiql/react/node_modules/@headlessui/react/dist/headlessui.esm.js
../../node_modules/@graphiql/react/dist/index.mjs
../../node_modules/graphiql/esm/index.js
../../.. etc
../../libs/editor/src/index.ts

Build failed because of webpack errors
Build process exited due to code 1 `

@mmswi
Copy link

mmswi commented Jan 20, 2025

and as a "hack" what I did was to use in package.json this override

"overrides": { "@headlessui/react": "2.2.0" },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants