Socket
Book a DemoInstallSign in
Socket

koa-no-cache

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

koa-no-cache

no cache for some paths or types

latest
Source
npmnpm
Version
2.0.0
Version published
Maintainers
2
Created
Source

NPM version Build status Test coverage License Dependency status

koa-no-cache

no cache for koa apps

example

Adding no cache header on some paths or types

const noCache = require('koa-no-cache')
const Koa = require('koa')
const app = new Koa()

app.use(noCache({
  paths: ['/users/(.*)'],
  types: ['manifest']
}))
  • paths
  • types

Adding no cache header globally

const noCache = require('koa-no-cache')
const Koa = require('koa')
const app = new Koa()

app.use(noCache({
  global: true
}))

License

MIT

Keywords

no-cache

FAQs

Package last updated on 23 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts