Thanks to visit codestin.com
Credit goes to github.com

Skip to content

patch require("react-dom/server.edge") calls in pages.runtime.prod.js so that they are try-catched #235

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

Merged
merged 3 commits into from
Jan 8, 2025

Conversation

dario-piotrowicz
Copy link
Contributor

@dario-piotrowicz dario-piotrowicz commented Jan 8, 2025

wrap require("react-dom/server.edge") calls in pages.runtime.prod.js in try-catches so that esbuild won't fail when encountering them, this doesn't guarantee that things won't blow up at runtime though


fixes #119

Copy link

changeset-bot bot commented Jan 8, 2025

🦋 Changeset detected

Latest commit: 4bdbc21

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@opennextjs/cloudflare Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

pkg-pr-new bot commented Jan 8, 2025

Open in Stackblitz

pnpm add https://pkg.pr.new/@opennextjs/cloudflare@235

commit: 4bdbc21

Copy link
Contributor

@vicb vicb left a comment

Choose a reason for hiding this comment

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

Thanks, looks good!

A few nits ;)

@dario-piotrowicz dario-piotrowicz merged commit dbcc4be into main Jan 8, 2025
7 checks passed
@dario-piotrowicz dario-piotrowicz deleted the dario/react-dom/server.edge branch January 8, 2025 21:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Could not resolve "react-dom/server.edge"
2 participants