cache-dir
An ES6 map-like cache with file-based backing
Example
var CacheDir = ; var cache = dir: '/path/to/store/cache' namespace: 'dirNameForThisParticularCache' lazy: true // Lazy load or eagerly load from disk on startup, eager by default; cache; // This actually blocks on the fs writecache; // returns bar cache; cache; cache; // Returns an array of keyscache; cache; // Returns an array of valuescache;
Other ES6 Map methods and properties are not yet implemented.
Installation
npm install cache-dir
Tests
npm test
Contributors
- David Ellis