Found code example at
Forked a sandbox(original is buggy and contains errors)
I want to use custom validation callbacks at each form input element, so I did provide options in register
, but validate
is triggered only at submition even useForm
is configured with
{ reValidateMode: "onChange" }
The question is how to start validate
on onChange
event in that case described in sandbox
but validate is triggered only at submition even useForm is configured with
Thats because reValidateMode
is triggered only after form submission. To validate before the form is submitted, you should use mode
property for onChange
, onBlur
etc events.