11 lines
266 B
TypeScript
11 lines
266 B
TypeScript
import { MiddlewareHandlerContext } from "$fresh/server.ts";
|
|
|
|
export async function handler(
|
|
_req: Request,
|
|
ctx: MiddlewareHandlerContext<{ test: string }>,
|
|
) {
|
|
ctx.state.test = "look, i'm set from a plugin!";
|
|
const resp = await ctx.next();
|
|
return resp;
|
|
}
|