Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/oak/middleware.ts>compose

A middleware framework for handling HTTP with Deno, Node, Bun and Cloudflare Workers 🐿️ 🦕
Very Popular
Latest
function compose
import { compose } from "https://deno.land/x/oak@v17.1.2/middleware.ts";

Compose multiple middleware functions into a single middleware function.

Type Parameters

optional
S extends State = Record<string, any>
optional
T extends Context = Context<S>

Returns

(context: T, next?: Next) => Promise<unknown>