zod
Version:
Typescript-first schema declaration and validation library with static type inference
14 lines (13 loc) • 473 B
TypeScript
import * as z from './base';
import { ZodUndefined } from './undefined';
import { ZodNull } from './null';
import { ZodUnion } from './union';
export interface ZodBooleanDef extends z.ZodTypeDef {
t: z.ZodTypes.boolean;
}
export declare class ZodBoolean extends z.ZodType<boolean, ZodBooleanDef> {
optional: () => ZodUnion<[this, ZodUndefined]>;
nullable: () => ZodUnion<[this, ZodNull]>;
toJSON: () => ZodBooleanDef;
static create: () => ZodBoolean;
}