UNPKG

async-constructor

Version:

The helper functions for creating classes that require asynchronous constructors.

4 lines (3 loc) 350 B
import { ReturnTypeOfConstructor } from 'hotypes'; import { Constructor } from 'justypes'; export declare function mixinAsyncConstructor<Base extends Constructor<any>>(base: Base, asyncConstructor: (...args: ConstructorParameters<Base>) => PromiseLike<void>): new (...args: ConstructorParameters<Base>) => PromiseLike<ReturnTypeOfConstructor<Base>>;