-
Notifications
You must be signed in to change notification settings - Fork 4.8k
@wordpress/block-library peer dependency maximum react version is 18 #67987
Copy link
Copy link
Closed
Labels
Needs DecisionNeeds a decision to be actionable or relevantNeeds a decision to be actionable or relevant[Package] Block editor/packages/block-editor/packages/block-editor[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
I expect in a project with :
// package.json
{
"name": "deleteme",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"description": "",
"dependencies": {
"react": "^19.0.0",
"react-dom": "^19.0.0"
}
}To be able to install the @wordpress/block-library package:
npm install -D @wordpress/block-libraryExpected outcome: it installs without issue.
Actual outcome:
╰─ npm install ─╯
npm error code ERESOLVE
npm error ERESOLVE unable to resolve dependency tree
npm error
npm error While resolving: deleteme@1.0.0
npm error Found: react@19.0.0
npm error node_modules/react
npm error react@"^19.0.0" from the root project
npm error
npm error Could not resolve dependency:
npm error peer react@"^18.0.0" from @wordpress/block-library@9.14.0
npm error node_modules/@wordpress/block-library
npm error dev @wordpress/block-library@"^9.14.0" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
npm error
npm error
npm error For a full report see:
npm error /Users/kennedyb/.npm/_logs/2024-12-13T20_59_18_771Z-eresolve-report.txt
npm error A complete log of this run can be found in: /Users/kennedyb/.npm/_logs/2024-12-13T20_59_18_771Z-debug-0.logCan this package be changed to support React 19?
Step-by-step reproduction instructions
Written above
Screenshots, screen recording, code snippet
No response
Environment info
No response
Please confirm that you have searched existing issues in the repo.
- Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
- Yes
Please confirm which theme type you used for testing.
- Block
- Classic
- Hybrid (e.g. classic with theme.json)
- Not sure
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Needs DecisionNeeds a decision to be actionable or relevantNeeds a decision to be actionable or relevant[Package] Block editor/packages/block-editor/packages/block-editor[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Type
Fields
Give feedbackNo fields configured for issues without a type.