koache:基于节点缓存的用于缓存响应的Koa中间件

时间:2021-02-03 17:38:02
【文件属性】:
文件名称:koache:基于节点缓存的用于缓存响应的Koa中间件
文件大小:24KB
文件格式:ZIP
更新时间:2021-02-03 17:38:02
middleware koa cache KoaJavaScript 柯阿奇 Koache是​​使用来缓存请求的小型中间件。 Koache将缓存应用程序的每个路径,因此您可以将其与结合使用 const Koa = require ( "koa" ) ; const cache = require ( "koache" ) ; const app = new Koa ( ) ; // See node-cache documentation to see allowded options app . use ( cache ( { stdTTL : 10 } ) ) ; app . use ( async ctx => { ctx . body = "sma
【文件预览】:
koache-master
----.eslintrc.json(30B)
----yarn.lock(53KB)
----test.js(317B)
----README.md(660B)
----.gitignore(914B)
----index.js(357B)
----package.json(509B)

网友评论