Skip to main content
Version: 1.2.0-beta1

Type Alias: CompiledValidator()

CompiledValidator = (value, path?) => JsonSchemaValidationError[]

Defined in: src/Mnemonic/json-schema.ts:172

A pre-compiled validation function generated by compileSchema.

Accepts a value and an optional JSON Pointer path for error reporting. Returns an array of validation errors (empty = valid).

Parameters

ParameterType
valueunknown
path?string

Returns

JsonSchemaValidationError[]