isPromise
Test if a value is a promise.
isPromise(obj)
Return true
if obj
is an instance of promise or .toString
returns "[object Promise]"
.
canReflect.isPromise(Promise.resolve()); // -> true
Parameters
- obj
{*}
:the object to test for Promise traits.
Returns
{Boolean}
: