pixl-cache

JSON →
library 1.1.1 ·javascript
verified Jun 7, 2026

Simple LRU (Least Recently Used) cache module for Node.js. Current version 1.1.1 provides a hash-map-backed LRU cache with automatic eviction of least recently used items when max key count or byte size is exceeded. Supports optional item expiration (TTL), custom metadata, event listeners for evictions, and stats tracking. Implemented with a double-linked list for efficient LRU ordering. No external dependencies. Suitable for scenarios requiring a lightweight, predictable caching solution with configurable limits based on item count or byte size. Lower-level and less feature-rich than alternatives like lru-cache, but has zero dependencies and straightforward API.