UNPKG

run-async

Version:

Utility method to run function either synchronously or asynchronously using the common `this.async()` style.

6 lines (4 loc) 157 B
declare function runAsync<F extends (...args: any[]) => any>( func: F, ): (...args: Parameters<F>) => Promise<Awaited<ReturnType<F>>>; export = runAsync;