High-performance caching library for Node.js and browser environments supporting LRU and LFU eviction policies with O(1) complexity for all operations. Version 2.0.3 requires Node >=18.18.2. Ships TypeScript definitions. Differentiates from other caches by supporting both LRU and LFU engines, custom hash tables via symbols, and a unified API with clearAll and toArray methods for LRU. Offers configurable maximum size. Actively maintained with regular releases.
No compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Always use named import. CommonJS require works but default is ESM.
Set engine via option string, not imported class.
Engine key is uppercase: 'LRU' or 'LFU'.
Shows creating a cache instance, adding, getting, checking, removing, and iterating items.
Breaking-change detection hasn't run for this library yet.
CVE tracking and dependency tree are planned for a later release.