-
Notifications
You must be signed in to change notification settings - Fork 861
Closed
Labels
Package: @react-email/tailwindPackage: react-emailThis is the CLI we generally use as just `email` on the temrinal.This is the CLI we generally use as just `email` on the temrinal.Type: BugConfirmed bugConfirmed bug
Description
Describe the Bug
Hello,
I have recently been trying to migrate an app we have been using from next-auth 4 to the next-auth 5 beta. Beta allows for the next-auth middleware to run on edge, however @react-email/render doesn't seem to be compatible with it.
It fails with the following message
[Error: Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.]
[Error: Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.]
⨯ node_modules\.pnpm\[email protected][email protected][email protected]\node_modules\next\dist\esm\build\noop-react-dom-server-legacy.js (6:10) @ renderToStaticMarkup
⨯ Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.
null
⨯ node_modules\.pnpm\[email protected][email protected][email protected]\node_modules\next\dist\esm\build\noop-react-dom-server-legacy.js (6:10) @ renderToStaticMarkup
⨯ Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.
null
[Error: Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.]
⨯ node_modules\.pnpm\[email protected][email protected][email protected]\node_modules\next\dist\esm\build\noop-react-dom-server-legacy.js (6:10) @ renderToStaticMarkup
⨯ Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.
null
[Error: Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.]
⨯ node_modules\.pnpm\[email protected][email protected][email protected]\node_modules\next\dist\esm\build\noop-react-dom-server-legacy.js (6:10) @ renderToStaticMarkup
⨯ Internal Error: do not use legacy react-dom/server APIs. If you encountered this error, please open an issue on the Next.js repo.
Which package is affected (leave empty if unsure)
@react-email/render
Link to the code that reproduces this issue
https://github.com/VaniaPopovic/react-email-repro
To Reproduce
Clone the above repositiory and head to http://localhost:3000/api/test
- The sample renders the vercel-invite-user in a node endpoint ( similar to what next-auth is doing when trying to send the confirmation email in v4)
- The sample fails to render when using
export const runtime = "edge";Expected Behavior
For render and renderAsync to work in both runtimes
What's your node version? (if relevant)
20.6.1
Metadata
Metadata
Assignees
Labels
Package: @react-email/tailwindPackage: react-emailThis is the CLI we generally use as just `email` on the temrinal.This is the CLI we generally use as just `email` on the temrinal.Type: BugConfirmed bugConfirmed bug