dreambox

0.1.1 • Public • Published

Dreambox

Available strategies are listed in here

For e.g. memory strategy,

$ npm install catbox-memory --save

Then in your code,

const cache = new Dreambox('memory', { segment: 'january', ttl: 10000 });
await cache.set('hurray', { hiphip: 'Yay!' });
const stored = await cache.get('hurray');
console.log(stored);
// { item: { hiphip: 'Yay!' }, stored: 1463699257301, ttl: 98000 }

Credits

Copyright © 2016 Dhi Aurrahman

Package Sidebar

Install

npm i dreambox

Weekly Downloads

2

Version

0.1.1

License

MIT

Last publish

Collaborators

  • diorahman