A lightweight, promise-based concurrency queue for Node.js and browsers. Current stable version is 2.2.5 (last published in 2016). It limits the number of concurrently executing async functions and the maximum queue size. Key differentiators: simple API (add, getQueueLength, getPendingLength), configurable Promise implementation (supports custom promise libraries like Vow or jQuery), and no dependencies. Alternative to async.queue or p-limit with a minimal footprint.
npm install promise-queueNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to create a queue with concurrency limit and add async functions that return promises.
Consider using p-limit or p-queue for active maintenance and better error handling.
Call Queue.configure(require('vow').Promise) or provide your own promise constructor.Always wrap the promise-returning operation in a function: queue.add(() => someAsyncCall()).
Check queue.getQueueLength() before adding, or set maxQueued to Infinity to avoid synchronous throws.
Use `import Queue from 'promise-queue'` or `const Queue = require('promise-queue')`.Always chain .catch on the promise returned by queue.add, or use async/await with try/catch.
Change to `import Queue from 'promise-queue'` (no curly braces).
No dependency data recorded yet.