@metreeca/core - v0.10.0
    Preparing search index...

    Function isPromise

    • Checks if a value is a promise.

      Admits only native Promise instances, so that catch() and finally() may be relied on alongside then(); foreign promise implementations and bare thenables are rejected and matched by isPromiseLike instead.

      Type Parameters

      • T = unknown

        The type of the promised value

      Parameters

      • value: unknown

        The value to check

      Returns value is Promise<T>

      True if the value is a Promise instance; false otherwise