-
Notifications
You must be signed in to change notification settings - Fork 26.8k
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
2 copies of react get embedded inside generated edge-chunks #67694
Comments
For more details, it looks like these are both duplicated:
Easy to see if you run an unminified build |
Regarding cloudflare/next-on-pages#805, I have an app in production and one in development that has this bug too. During development, these are the logs:
I have Turbopack enabled and the error goes away after restarting. Sadly not sure how to actually trigger it in development. I haven't found a reproduction step, it just "happens" after some time. If any information is needed, just mention me! |
@bjarn I'm facing this while previewing deployments with cloudflare/next-on-pages (using cf-preview), and managed to reproduce it easily by using browser's back and forward on routes wrapped by a ContextProvider. Maybe that can help you reproducing in dev. |
Link to the code that reproduces this issue
https://github.com/threepointone/next-repro-react-dupe
To Reproduce
Current vs. Expected behavior
We're tracking down an issue where useContext isn't available on React, and discovered that webpack's chunks generated for the edge stuff seems to have multiple versions of react embedded into it. Here's a repro https://github.com/threepointone/next-repro-react-dupe
Provide environment information
Which area(s) are affected? (Select all that apply)
Middleware, Output (export/standalone)
Which stage(s) are affected? (Select all that apply)
next build (local)
Additional context
No response
The text was updated successfully, but these errors were encountered: