memory-cache-ttl

JSON →
library 1.0.52 ·javascript
verified Jun 7, 2026

A simple, performant in-memory cache with configurable Time To Live (TTL) for Node.js. Current stable version is 1.0.52. It provides global and per-key TTL, automatic expiry cleanup via configurable interval, optional TTL randomization, extend-on-hit behavior, and an async onInterval callback to refresh cache entries. The package has zero dependencies and uses CommonJS. It is lightweight and minimal compared to more feature-rich caches like node-cache or lru-cache.