This package has been deprecated

Author message:

move to @the-/cache ( https://github.com/the-labo/the/tree/master/packages/cache#readme )

the-cache

2.1.0 • Public • Published

the-cache

Build Status npm Version JS Standard

Cache manager of the-frameworks

Installation

$ npm install the-cache --save

Usage

'use strict'

const theCache = require('the-cache')

async function tryExample () {
  const cache = theCache({
    max: 10000,
    maxAge: 1000 * 60 * 60
  })

  cache.set('foo', 'bar')
  const foo = cache.get('foo')
  console.log(foo) // -> 'bar'
  cache.reset() // remove all
}

tryExample().catch((err) => console.error(err))

API Guide

License

This software is released under the MIT License.

Links

Readme

Keywords

Package Sidebar

Install

npm i the-cache

Weekly Downloads

2

Version

2.1.0

License

MIT

Unpacked Size

24.3 kB

Total Files

34

Last publish

Collaborators

  • okunishinishi