christianalfoni/formsy-react

raise "onValidationComplete" event for users?

breezewish opened this issue · 0 comments

Currently formsy supports onValid() and onInvalid() at a form basis. However sometimes we need to get notified when the validation state of a single form input has been changed. For example, in a sign up page we may have "send sms" button as well as "submit" button, while the disable state of "send sms" button should be based on the phone number input and the disable state of "submit" button should be based on all inputs.

Currently we can only simulate this behavior by adding onChange to the phone input and invoke a validate there. However sometimes we cannot get the reference of the phone input itself so that this method doesn't always work.