Skip to content

SafeParseResult

type SafeParseResult<T> = { data: T; success: true } | { error: SchemaError; success: false }

Result of a schema parse operation.

On success, data holds the parsed value typed as T. On failure, error holds a SchemaError describing which fields failed.

Last updated: