pub unsafe fn new_promise(
context: *mut JSContext,
) -> Result<QuickJsPromiseAdapter, JsError>
Expand description
create a new Promise you can use this to respond asynchronously to method calls from JavaScript by returning a Promise
ยงSafety
When passing a context pointer please make sure the corresponding QuickJsContext is still valid