you can use lru-cache and do: const cache = lru({ max: 500, maxAge: 24 * 60 * 60 * 1000, }) if (cache.has(ctx.req.url)) { ctx.body ...
確定! 回上一頁