Skip to main content
Module

x/zoic/zoic.ts>Zoic#use

A caching middeware library for Deno HTTP framework, Oak.
Go to Latest
method Zoic.prototype.use
import { Zoic } from "https://deno.land/x/zoic@v1.0.2/zoic.ts";

Primary caching middleware method on user end. Resposible for querying cache and either returning results to client/attaching results to ctx.state.zoic (depending on user options) or, in the case of a miss, signalling to make response cachable.

Parameters

ctx: Context
next: () => Promise<unknown>