UNPKG

concurrent-worker

Version:
3 lines (2 loc) 263 B
import { IPoolConfig, IWorker, IWorkerContext, WorkerThis } from "./types"; export declare const pool: <T extends unknown[], C extends IWorkerContext, R>(task: string | ((this: WorkerThis<C>, ...args: T) => R), config?: IPoolConfig<T, C, R>) => IWorker<T, C, R>;