@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 07:15 UTC

main
ts 13 lines 582 Bytes
Raw
1 // Managed-mode middleware (`src/middleware/*.ts`): waku's managed server
2 // entry collects these via `import.meta.glob` and hands them to the adapter,
3 // which runs them (via `middlewareRunner`) ahead of the RSC middleware for
4 // every worker-handled request. Sets a response header the smoke test
5 // asserts in both live and dev modes.
6 import type { Context } from "hono";
7
8 export default function headersMiddleware(_opts: unknown) {
9 return async (c: Context, next: () => Promise<void>) => {
10 await next();
11 c.res.headers.set("x-waku-middleware", "fixtures-waku");
12 };
13 }