Extensions for kotlin.js.Promise

asDeferred

fun <T> Promise<T>.asDeferred(): Deferred<T>

Converts this promise value to the instance of Deferred.

await

suspend fun <T> Promise<T>.await(): T

Awaits for completion of the promise without blocking.