X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=examples%2Ftypescript%2Fpool.ts;h=c55c4e96557dc8fcb400847745b0ac2c5ee014c7;hb=45560c0539e5668157f1352c984bcd2e8ded6124;hp=144d55002bd048ea865365cb6696cdb887745230;hpb=ac35d84eacd6a5dec2373efb3afc083a73ea2c2e;p=poolifier.git diff --git a/examples/typescript/pool.ts b/examples/typescript/pool.ts index 144d5500..c55c4e96 100644 --- a/examples/typescript/pool.ts +++ b/examples/typescript/pool.ts @@ -1,12 +1,14 @@ import { dirname, extname, join } from 'node:path' import { fileURLToPath } from 'node:url' -import type { MyData, MyResponse } from './worker.js' + import { + availableParallelism, DynamicThreadPool, - FixedThreadPool, - availableParallelism + FixedThreadPool } from 'poolifier' +import type { MyData, MyResponse } from './worker.js' + const workerFile = join( dirname(fileURLToPath(import.meta.url)), `worker${extname(fileURLToPath(import.meta.url))}`