after.d.ts 438 B

123456789101112131415
  1. /**
  2. * 创建一个函数, 调用次数超过 count 次之后执行回调并将所有结果记住后返回
  3. * @param count 次数
  4. * @param callback 回调
  5. * @param context 上下文
  6. */
  7. export declare function after<C>(count: number, callback: (this: C, ...args: any[]) => any, context?: C): (this: any,...args: any[]) => any;
  8. declare module './ctor' {
  9. interface XEUtilsMethods {
  10. after: typeof after;
  11. }
  12. }
  13. export default after