-
In the route event handler I need to send response quickly and then do some long running tasks. Cloudflare would kill the worker after sending response, so I need to call ctx.waituntil before the return. But how write that code universally so it will work on the node dev server and Cloudflare production environment? I would like to avoid this:
|
Beta Was this translation helpful? Give feedback.
Answered by
iBobik
Oct 26, 2024
Replies: 1 comment
-
Found undocumented |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
iBobik
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Found undocumented
event.waitUntil
in Nitro function which calls Cloudflare’s function and also has fallback on the dev server.