-
-
Notifications
You must be signed in to change notification settings - Fork 703
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: update for React 19 compatibility #4247
base: dev
Are you sure you want to change the base?
Conversation
View Deployment
|
268a9d4
to
81ac375
Compare
Playwright test resultsDetails 23 tests across 10 suites Failed testschromium › memory/memory.spec.ts › memory |
8d9644f
to
095e1e6
Compare
6bfdf8d
to
287f12e
Compare
829c2a6
to
f1844d8
Compare
ceb870b
to
ad2bd77
Compare
ad2bd77
to
ac4a6c7
Compare
ac4a6c7
to
d01f2c9
Compare
TODO
BREAKING CHANGES
In React 16, the
render
method is imported from"react-dom"
, while in React 19, thecreateRoot
method is imported from"react-dom/client"
. This creates a path compatibility issue. Therefore, in projects using React 16, you need to use an alias to mapreact-dom/client
to a polyfill.vite.config.ts
export default defineConfig({ plugins: [react()], resolve: { alias: { + "react-dom/client": path.resolve(__dirname, './src/client.ts'), } } }
src/client.ts
Additional Compatibility Note
In React 19 projects, certain components may trigger the following warnings. We will fix these issues gradually in future UI refactoring efforts.
Please don’t worry, this will not affect the functionality of your application.
Pull Request Checklist