UNPKG

promisify-4loc

Version:

Promisify a callback-style function in just 4 lines of code

4 lines (3 loc) 142 B
declare type CBAPI = (...args: Array<any>) => void; declare function pify<T>(api: CBAPI): (...args: Array<any>) => Promise<T>; export = pify;