A validator is a waitable that produces a ValidationResult, indicating either validity or a problem, if all of its dependencies are loaded (or if the validator is disabled).
ValidationResult
Basic example:
const myBindingValidator = useValidator(myBinding, checkEquals('hello', 'expected "hello"'), { id: 'myBindingValidator' });console.log('isValid', myBindingValidator.value.get()?.isValid); Copy
const myBindingValidator = useValidator(myBinding, checkEquals('hello', 'expected "hello"'), { id: 'myBindingValidator' });console.log('isValid', myBindingValidator.value.get()?.isValid);
A validator is a waitable that produces a
ValidationResult
, indicating either validity or a problem, if all of its dependencies are loaded (or if the validator is disabled).Basic example: