UNPKG

graphql

Version:

A Query Language and Runtime which can target any service.

13 lines (12 loc) 355 B
import type { PromiseOrValue } from "./PromiseOrValue.js"; /** * Based on Promise.withResolvers proposal * https://github.com/tc39/proposal-promise-with-resolvers * * @internal */ export declare function promiseWithResolvers<T>(): { promise: Promise<T>; resolve: (value: T | PromiseOrValue<T>) => void; reject: (reason?: any) => void; };