🔎 Checks if the given value is a Promise object.
Syntax
import { isPromise } from '@opentf/std';
isPromise(val: unknown): val is Promise<unknown>Parameters
val: The value to check.
Returns
true if the value is a Promise, false otherwise.
Examples
isPromise(Promise.resolve()) //=> true
isPromise({}) //=> false