cachedir
Provides a directory where the OS wants you to store cached files.
Last updated 3 years ago by linusu .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install cachedir 
SYNC missed versions from official npm registry.

node-cachedir

Provides a directory where the OS wants you to store cached files.

Installation

npm install --save cachedir

Usage

const cachedir = require('cachedir')

console.log(cachedir('myapp'))
// e.g.
//=> '/Users/linus/Library/Caches/myapp'
//=> '/home/linus/.cache/myapp'
//=> 'C:\Users\linus\AppData\Local\myapp\Cache'

API

cachedir(id)

  • id (string, required)
  • returns string

Return path to an appropriate place to store cache files.

Current Tags

  • 2.4.0                                ...           latest (3 years ago)

15 Versions

  • 2.4.0                                ...           3 years ago
  • 2.3.0                                ...           7 years ago
  • 2.2.0                                ...           8 years ago
  • 2.1.0                                ...           8 years ago
  • 2.0.0                                ...           8 years ago
  • 1.3.0                                ...           8 years ago
  • 1.2.0                                ...           9 years ago
  • 1.1.1                                ...           10 years ago
  • 1.1.0                                ...           10 years ago
  • 1.0.0                                ...           11 years ago
  • 0.1.4                                ...           11 years ago
  • 0.1.3                                ...           11 years ago
  • 0.1.2 [deprecated]           ...           11 years ago
  • 0.1.1                                ...           12 years ago
  • 0.1.0                                ...           13 years ago
Maintainers (1)
Downloads
Total 86
Today 0
This Week 0
This Month 16
Last Day 0
Last Week 15
Last Month 29
Dependencies (0)
None
Dev Dependencies (4)

© 2010 - cnpmjs.org x YWFE | Home | YWFE