import 'typings-global'; import * as typedPromisify from 'typed-promisify'; export interface IResolve { (value?: T | Promise): void; } export interface IReject { (reason?: any): void; } export declare class Deferred { promise: Promise; resolve: IResolve; reject: IReject; constructor(); } export declare let defer: () => Deferred; /** * Creates a new resolved promise for the provided value. */ export declare let resolvedPromise: (value?: T) => Promise; /** * Creates a new rejected promise for the provided reason. */ export declare let rejectedPromise: (err: any) => Promise; export declare let promisify: typeof typedPromisify.promisify; export declare let map: typeof typedPromisify.map;