Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/typebox_deno/src/typebox.ts>TypeGuard.TKindOf

JSON Schema Type Builder with Static Type Resolution for TypeScript
Latest
function TypeGuard.TKindOf
import { TypeGuard } from "https://deno.land/x/typebox_deno@0.31.22/src/typebox.ts";
const { TKindOf } = TypeGuard;

Returns true if the given value is a TKind with the given name.

Type Parameters

T extends string

Parameters

schema: unknown
kind: T

Returns

schema is Record<PropertyKey, unknown> & { [Kind]: T; }