UNPKG

zod

Version:

Typescript-first schema declaration and validation library with static type inference

14 lines (13 loc) 466 B
import * as z from './base'; import { ZodUndefined } from './undefined'; import { ZodNull } from './null'; import { ZodUnion } from './union'; export interface ZodStringDef extends z.ZodTypeDef { t: z.ZodTypes.string; } export declare class ZodString extends z.ZodType<string, ZodStringDef> { optional: () => ZodUnion<[this, ZodUndefined]>; nullable: () => ZodUnion<[this, ZodNull]>; toJSON: () => ZodStringDef; static create: () => ZodString; }