1
2
3
4
5
// SPDX-License-Identifier: 0BSD
import type { MiddlewareHandler } from "npm:hono";
export const toHonoHandler =
(handler: (req?: Request) => Promise<Response>): MiddlewareHandler => async (c) => (c.res = await handler(c.req.raw));
Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
Comments
Nobody has commented on this val yet: be the first!
March 8, 2024