A functional, data-oriented priority queue (max-heap) for Node.js, version 0.2.1. Designed to be tiny (~150 lines), pure ES module, and — critically — does not allocate memory at runtime after initial creation. It is a preallocated array-based heap offering queue, dequeue, isEmpty, clear, delete, and list operations. Unlike typical priority queue libraries that allocate dynamically, this one is suited for performance-critical or real-time applications where GC pauses must be avoided. The package is actively maintained and has tests via GitHub Actions.
No compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
ESM-only since v0.1.0; CommonJS require() will throw.
create is not a named export; it is a method on the default export.
API is functional, not object-oriented. Methods are on the PQ module, not the queue object.
Create a priority queue, insert items with priorities, and dequeue them in order of descending priority. Shows that dequeue returns undefined when empty.
Breaking-change detection hasn't run for this library yet.
CVE tracking and dependency tree are planned for a later release.