-
Notifications
You must be signed in to change notification settings - Fork 670
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
Dynamic Code Evaluation (e. g. 'eval', 'new Function', 'WebAssembly.compile') not allowed in Edge Runtime #1105
Comments
Dude, I have the exact same problem. After installing each component individually and removing the tailwind component this error stopped. :( |
Thanks for this, it on my side still not building. Maybe your solution will help |
Same problem, unusable on edge runtime |
You can use this hack until the PR is merged. In export const config = {
matcher: ["/business/:path*", "/join"],
unstable_allowDynamic: [
"**/node_modules/.pnpm/@[email protected][email protected]/**", // use a glob to allow anything in the function-bind 3rd party module
],
}; |
We're running into the same issue. It's unusable on the edge. We are rendering emails through inngest. |
I managed to figure out a work around by uninstalling react-email/components and just using the individual packages. I'm fairly sure it's the tailwind package that's causing the issue. To the maintainers of this project: I really would fix this one because it is extremely common to use this package in an edge environment. Typically you're sending emails from a job queue like ingest and the only way that ingest is going to work is if it's streaming and so it needs to be in an edge environment. So I would really give this one some attention. Just my two cents. |
I wonder if the new engine for Tailwind will just magically fix it because it's such a big rewrite. |
Hey there!
Not sure, if |
Same problem using next-auth@5. Your solution helped, thanks! |
This was the solution that worked for me as well, but it would be a lot nicer if this was fixed so I could just use the single package. |
It would also be great to explicitly document that the |
Worked for me |
Thanks buddy it works for me |
Thanks a lot. Worked for me too! |
+1 |
Just to share a few cents on this: we are also using Inngest and we try to use the Edge Runtime as much as possible. However, we also really want to use Tailwind. |
Thanks, it works! pnpm |
Unistalling this package @react-email/components
|
We just merged #1383 and released it under canary, |
Describe the Bug
Hello, this is the one I was referring to to in the other ticket @gabrielmfern,
I have a monorepo with an auth package, an email package and my main app that consumes both of them.
My desire is for users to login through next-auth and have next-auth send out an email with resend of a login link that is styled with react email.
I have been trying to have the next-auth middleware run on edge in order to make it faster.
The problem that I'm experiencing is that the project works well on dev, but when trying to build and deploy to vercel, it fails with
I've been using the canary versions of both @react-email/components & @react-email/render cause they contain fixes that I need to run on edge : #1079
I'm not sure if it's a regression or a problem caused by a different library eg. NextAuth or Next itsself.
It took me a while to create the reproduction because I have attempted:
Which package is affected (leave empty if unsure)
@react-email/components
Link to the code that reproduces this issue
https://github.com/VaniaPopovic/react-email-repro
To Reproduce
Expected Behavior
For it to render the email without a problem
What's your node version? (if relevant)
20.6.1
The text was updated successfully, but these errors were encountered: