isPromiseLike<T>(input): input is T extends PromiseLike<Value> ? PromiseLike<Value> : PromiseLike<unknown>
Checks if a value is promise like. This means that the value has a .then() function property.
It might not have the other properties expected from the Promise class, however.
Type Parameters
T
Parameters
input: unknown
Returns input is T extends PromiseLike<Value> ? PromiseLike<Value> : PromiseLike<unknown>
Checks if a value is promise like. This means that the value has a
.then()
function property. It might not have the other properties expected from thePromise
class, however.