Closed dgmltn closed 2 months ago
Thank you so much for this library 🙏 ! I have an easy suggestion for improvement:
It would be pragmatic to be able to use QuickJSContext with try-with-resources (in Java) or .use (in Kotlin), like this:
try (QuickJSContext context = QuickJSContext.create()) { ... }
QuickJSContext.create().use { context -> ... }
But that requires an object that implements Closeable. This should be as simple as adding this method to QuickJsContext:
Closeable
QuickJsContext
public void close() { destroy() }
ok, I will add it in the next version.
Thank you so much for this library 🙏 ! I have an easy suggestion for improvement:
It would be pragmatic to be able to use QuickJSContext with try-with-resources (in Java) or .use (in Kotlin), like this:
But that requires an object that implements
Closeable
. This should be as simple as adding this method toQuickJsContext
: