A lightweight, promise-based worker queue for TypeScript and JavaScript that limits concurrent task execution. Current stable version is 0.1.0. It offers a simple API for enqueuing async tasks with a configurable concurrency limit, making it suitable for throttling API calls or managing resource-intensive operations. Differentiator: minimal overhead with no external dependencies, designed specifically for TypeScript projects.
npm install queue-tsNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates a queue with concurrency 2, enqueues three tasks, and waits for all to finish.
Implement retry logic within the task function.
If strict FIFO is needed, ensure concurrency is 1.
Use new Queue(concurrency) or new Queue({ concurrency })Enqueue all tasks before calling onEmpty().
Use import { Queue } from 'queue-ts' (ESM).Upgrade to queue-ts@0.1.0 and ensure TypeScript 3.8+.
npm install queue-ts and ensure 'moduleResolution' is 'node' in tsconfig.json.
No dependency data recorded yet.