You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unless I missed something, the validationValue function is called on elements when:
the form is displayed
a validationEvent occurs
So in the doc:
// This is an optional method that lets you hook into the validation event
should be more:
// This is an optional method that lets you hook into the validation process, which occurs at form startup and upon a validation event
My second remark is that I need to distinguish between the startup call and the other ones. The reason is that I perform async validation and I don't want this to occur at startup time, because it takes time and I am sure my initial data is correct.
Did you think about that? Are you sure validating at startup is required? If it is, maybe there could be a template argument saying "please don't validate at startup"? Or a validationValue boolean argument saying "this call is the startup call"?
While we discuss this, can you think of a workaround to detect the startup call inside validationValue?
The text was updated successfully, but these errors were encountered:
I definitely support getting rid of the validation on startup, in most cases it is just a burden. We can support this behavior more elegantly with a method on the form block to validate containing elements that can run be manually on startup (or whenever else we need to validate).
Unless I missed something, the
validationValue
function is called on elements when:So in the doc:
should be more:
My second remark is that I need to distinguish between the startup call and the other ones. The reason is that I perform async validation and I don't want this to occur at startup time, because it takes time and I am sure my initial data is correct.
Did you think about that? Are you sure validating at startup is required? If it is, maybe there could be a template argument saying "please don't validate at startup"? Or a
validationValue
boolean argument saying "this call is the startup call"?While we discuss this, can you think of a workaround to detect the startup call inside
validationValue
?The text was updated successfully, but these errors were encountered: