useFormSubmission()
Last updated
Last updated
Prop Name
Description
requiredFields
An optional array of field names to be checked when looking for visited fields.
If not passed, it will default to using registered fields.
Prop Name
Description
formChangeState
Either 'unchanged'
, 'staged'
, or 'committed'
.
getErrorMessages
Function that returns an array of all error messages on the form.
isValid
Boolean value representing no invalid fields.
isVisited
Boolean value representing all registered or optionally required fields being visited.
isSubmitting
Boolean value representing if the form is submitting.
submitForm
A programmatic function to submit the form rather than using a regular "submit"
type.
submissionState
String value of the submission state.
totalErrorMessages
Number of error messages.