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

chore: upgrade react version from 18 to 19 #63

Merged
merged 2 commits into from
Jan 30, 2025
Merged

Conversation

simotae14
Copy link
Contributor

What does it do?

Upgrade the react and react dom version from 18 to 19 (and react testing library to v16)

Why is it needed?

To uniform the react versions in the strapi repos

How to test it?

Use the blocks-react-renderer in your FE to consume the Blocks text editor data

@simotae14 simotae14 added the pr: chore Cleanups / dependencies / tooling / styling label Jan 29, 2025
@simotae14 simotae14 requested a review from remidej January 29, 2025 16:13
@simotae14 simotae14 self-assigned this Jan 29, 2025
package.json Outdated Show resolved Hide resolved
Comment on lines -28 to +36
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"require": "./dist/index.cjs",
"import": "./dist/index.js",
"source": "./src/index.ts",
"default": "./dist/index.js"
},
"./package.json": "./package.json"
},
"main": "./dist/index.js",
"module": "./dist/index.mjs",
"main": "./dist/index.cjs",
"module": "./dist/index.js",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you know why these changes are needed? the previous values match what we have in the monorepo

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to run the build script with no success, with this error message
`when I run yarn build I have these errors

[ERROR]

  • package.json with 'type: "module"' - 'exports["."].require' must end with ".cjs"
  • package.json with 'type: "module"' - 'exports["."].import' must end with ".js"`
    So I followed the error message and fixed the extensions

Copy link
Contributor

@remidej remidej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

@simotae14 simotae14 merged commit 0a4de24 into main Jan 30, 2025
2 checks passed
@simotae14 simotae14 deleted the chore/upgrade-react-19 branch January 30, 2025 13:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: chore Cleanups / dependencies / tooling / styling
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants