mirror of
https://github.com/resend/react-email.git
synced 2026-09-14 14:18:02 +08:00
fix: prevent process crash by rejecting error instead of throwing in renderToReadableStream (#3076)
Co-authored-by: gabriel miranda <gabrielmfern@outlook.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@react-email/render": patch
|
||||
---
|
||||
|
||||
fix process crashes in client errors
|
||||
@@ -29,7 +29,7 @@ export const render = async (node: React.ReactNode, options?: Options) => {
|
||||
progressiveChunkSize: Number.POSITIVE_INFINITY,
|
||||
onError(error) {
|
||||
// Throw immediately when an error occurs to prevent CSR fallback
|
||||
throw error;
|
||||
reject(error);
|
||||
},
|
||||
},
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user