AV6A
Denoβ€’3y agoβ€’
20 replies
AV6

calling a javascript function and waiting for the promise with `rusty_v8`

let result = function.call(scope, recv, &[]).expect("couldnt run");
/*i got this result which is a promise. now how do i get the value of the promise

let value = ??
*/

result.is_promise is true
promise state is Pending
scope.has_pending_background_tasks() is
false
which confuses me. Isnt this supposed to be true if there are unresolved promises?
Was this page helpful?