Simple in-memory key/value cache for Node.js. Version 0.2.0 is the latest stable release. Provides basic set, get, unset, exists, size, and clear operations with optional time-to-live in milliseconds. Less feature-rich than alternatives like node-cache, but minimal and dependency-free. Suitable for small-scale caching needs.
npm install easy-cacheNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Demonstrates basic set, get with TTL, and clear operations.
Use node-cache (npm install node-cache) or a similar maintained package.
Convert seconds to milliseconds: duration * 1000.
Use exists() to check existence before get() if distinction matters.
Use `const cache = require('easy-cache');`Run `npm install easy-cache` and ensure require path is correct.
Check key existence with exists() before accessing properties.
No dependency data recorded yet.