Box results of a promise
const promise = new Promise((resolve, reject) => { setTimeout(() => { resolve("Hello"); }, 1000);});let [result,error] = boxPromise(promise);
Soften promise
const promise = new Promise((resolve, reject) => { setTimeout(() => { resolve("Hello"); }, 1000);});softenPromise(promise);
Soften promise with timeout
const promise = new Promise((resolve, reject) => { setTimeout(() => { resolve("Hello"); }, 1000);});softenPromiseWithTimeout(promise, 500);
Generated using TypeDoc
Box results of a promise