暫無描述
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.d.ts 445B

12345678910111213
  1. export = asPromise;
  2. type asPromiseCallback = (error: Error | null, ...params: any[]) => {};
  3. /**
  4. * Returns a promise from a node-style callback function.
  5. * @memberof util
  6. * @param {asPromiseCallback} fn Function to call
  7. * @param {*} ctx Function context
  8. * @param {...*} params Function arguments
  9. * @returns {Promise<*>} Promisified function
  10. */
  11. declare function asPromise(fn: asPromiseCallback, ctx: any, ...params: any[]): Promise<any>;