StandardSchemaV1
Defined in: packages/validate/src/standard.ts:11
The Standard Schema interface, declared here rather than imported.
The spec is structural: a schema is anything carrying a ~standard property
of this shape. Declaring it locally costs twenty lines of types that vanish
at build time, and buys a self-contained .d.ts — no dependency for a
consumer to resolve, nothing for attw to trip over.
Type Parameters
Section titled “Type Parameters”Output
Section titled “Output”Output = unknown
Properties
Section titled “Properties”~standard
Section titled “~standard”
readonly~standard:object
Defined in: packages/validate/src/standard.ts:12
validate()
Section titled “validate()”
readonlyvalidate: (value) =>StandardResult<Output> |Promise<StandardResult<Output>>
Checks a value against the schema, returning the result or a promise of it.
Parameters
Section titled “Parameters”unknown
Returns
Section titled “Returns”StandardResult<Output> | Promise<StandardResult<Output>>
vendor
Section titled “vendor”
readonlyvendor:string
version
Section titled “version”
readonlyversion:1