A node-cache plugin for cache-service and standalone node-cache wrapper, version 2.0.0. Provides a robust caching layer with background refresh support, configurable expiration, and verbose logging. Designed to work seamlessly with cache-service and superagent-cache. Key differentiators: excellent mset() implementation allowing per-key, per-call, and per-instance expirations; public access to the underlying node-cache instance. Released as a stable package with node-cache 4.x as a peer dependency.
npm install cache-service-node-cacheNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows instantiation, setting, getting, and multi-setting with expiration options.
ensure using `new csNodeCache(config)`.
use explicit object params or always pass `expiration` as a number, then `refresh` as function, then `callback`.
check mset documentation for the correct object shape.
ensure package.json includes `"node-cache": "4.x"`.
wrap in Promise manually or use promisify.
use `import csNodeCache from 'cache-service-node-cache'` and `new csNodeCache()`.
run `npm install node-cache` and ensure version satisfies peer dependency.
always provide a callback function, i.e., `cache.get('key', (err, val) => { ... })`.