File

forms/src/validator.ts

Description

Implements logic to validate the current value of a form control as specified by the validation rules on a Blueriq Field.

Index

Methods

Constructor

constructor(validator: FieldValidator, frontendValidation: FrontendValidationBehavior)
Parameters :
Name Type Optional
validator FieldValidator No
frontendValidation FrontendValidationBehavior No

Methods

validate
validate(control: FormControl, field: Field, value: Value)

Validates an Angular FormControl and returns errors as expected by Angular's ValidatorFn. The provided value is obtained from the control's current value, converted into a Blueriq Value type.

Parameters :
Name Type Optional
control FormControl No
field Field No
value Value No
Returns : ValidationErrors | null

result-matching ""

    No results matching ""