Skip to main content

ValidatorMessageParameters

Structured built-in error data available to a configured message function.

Import​

import type { ValidatorMessageParameters } from '@ngblocks/form-nodes';

When to use it​

Use when writing reusable message functions that need built-in structured error data. The selected error kind determines which parameters are available.

Declaration​

type ValidatorMessageParameters<TKind extends keyof BuiltInValidationErrorMap> = Omit<BuiltInValidationErrorMap[TKind], keyof ValidationError | 'targetNode' | 'formNode'>;

Type parameters​

ParameterConstraintDefault
TKindkeyof BuiltInValidationErrorMapRequired