@serenity-is/corelib / ValidationRuleContext
Interface: ValidationRuleContext
Defined in: src/base/validationrule.ts:4
What a validation rule is checked with, besides the value and its parameters.
Properties
element?
optionalelement:HTMLElement
Defined in: src/base/validationrule.ts:6
The element being validated, e.g. the input of an editor.
getValue()?
optionalgetValue: (field) =>any
Defined in: src/base/validationrule.ts:8
Gets the value of another field of the form, e.g. for a rule comparing two fields.
Parameters
field
string
Returns
any