Schema
Summary
A sync, Standard Schema v1-compatible schema with a small chainable API.
Signature
type Schema<input, output> = SyncStandardSchema<input, output> & { ~run: (value: unknown, context: ValidationContext) => ValidationResult<output>; pipe: (checks: Check<output>[]) => Schema<input, output>; refine: (predicate: (value: output) => boolean, message?: string) => Schema<input, output>; transform: (transformer: (value: output) => newOutput) => Schema<input, newOutput> }