mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-07 08:17:05 +00:00
* Add definition for "throng". * Fix tslint errors. * Fix mistakes. * Fix mistake. * Replace "class" by "interface".
31 lines
489 B
TypeScript
31 lines
489 B
TypeScript
import throng = require("throng");
|
|
|
|
function masterFunction() { }
|
|
function startFunction(id: number) { }
|
|
|
|
throng((id: number) => {});
|
|
|
|
throng(startFunction);
|
|
throng(3, startFunction);
|
|
|
|
throng({
|
|
workers: 4,
|
|
master: masterFunction,
|
|
start: startFunction
|
|
});
|
|
|
|
throng({
|
|
workers: 16,
|
|
grace: 1000,
|
|
master: masterFunction,
|
|
start: startFunction
|
|
});
|
|
|
|
throng({
|
|
workers: 4,
|
|
lifetime: 10000,
|
|
grace: 4000,
|
|
master: masterFunction,
|
|
start: startFunction
|
|
});
|