esbuild icon indicating copy to clipboard operation
esbuild copied to clipboard

Consider removing esbuild.stop() requirement for Deno

Open jed opened this issue 3 years ago • 2 comments

Per the esbuild docs about Deno:

It has basically the same API as esbuild's npm package with one addition: you need to call stop() when you're done because unlike node, Deno doesn't provide the necessary APIs to allow Deno to exit while esbuild's internal child process is still running.

and Deno release notes from three days ago:

Finally, two new methods Child.ref() and Child.unref() were added that allow you to tell Deno that it shouldn't wait for subprocess completion before exiting your program.

is it possible to remove the stop() requirement using these Child.ref() and Child.unref() methods?

jed avatar Jul 24 '22 05:07 jed

Thanks for the heads up. However, the API is unstable as far as I can tell, and I don't want to build esbuild on top of unstable APIs that could randomly break. So I'm marking this as unactionable until the API is stabilized.

evanw avatar Jul 24 '22 15:07 evanw

Sounds good, I'll keep an eye on it and report back when it's stable.

jed avatar Jul 25 '22 12:07 jed

I'm closing this because the API mentioned above has since been deprecated in favor of something else. We can consider this if a relevant API is ever made stable.

evanw avatar Dec 01 '22 21:12 evanw