import { zValidator } from "@hono/zod-validator";import { Hono } from "hono";import { z } from "zod";const app = new Hono();const route = app.post( "/posts", zValidator( "form", z.object({ body: z.string(), }) ), (c) => { const validated = c.req.valid("form"); // ... use your validated data });
Argument of type 'MiddlewareHandler<Env, string, { in: { form: { body: string | File; }; }; out: { form: { body: string; }; }; }>' is not assignable to parameter of type 'H<BlankEnv, "/posts", BlankInput, HandlerResponse<any>>'.