Checks if a value is a Promise.
value
Returns true if the value is a Promise
true
const value = new Promise(() => {});const result = isPromise(value);console.log(result); // true
true if value is a Promise, otherwise false
false
the Promise value type
the value to check
Generated using TypeDoc
Checks if a
valueis a Promise.Example
Returns
trueif the value is a PromiseReturns
trueifvalueis a Promise, otherwisefalse