UNPKG

jsonv-ts

Version:

JSON Schema builder and validator for TypeScript with static type inference, Hono middleware for OpenAPI generation and validation, and MCP server/client implementation. Lightweight, dependency-free, and built on Web Standards.

9 lines (8 loc) 287 B
import { Resolver } from "./resolver"; import type { Schema } from "../schema/schema"; export type CoercionOptions = { dropUnknown?: boolean; resolver?: Resolver; depth?: number; }; export declare function coerce(s: Schema, _value: unknown, opts?: CoercionOptions): unknown;