The ArrayField accepts a template and a schema and renders them for each entry in whichever array field is specified in props.name. This component provides a wrapper so end users do not have to manage looping through their array, or working with Formik helpers, instead allowing them to just focus on what their React components will look like.
This function is used to validate an email address, while returning error messages if an email is invalid. The logic is as follows:1. Ensure the email address is a string. If it’s not, return an error message 2. Ensure that one of the following is true, else output an error message: 2a. The field is not required -AND- the field has no entered value 2b. The value in the field matches an email validation regular expression
Conditions for valid SSN from the original 1010ez pdf form: ‘123456789’ is not a valid SSN A value where the first 3 digits are 0 is not a valid SSN A value where the 4th and 5th digits are 0 is not a valid SSN A value where the last 4 digits are 0 is not a valid SSN A value with 3 digits, an optional -, 2 digits, an optional -, and 4 digits is a valid SSN 9 of the same digits (e.g., ‘111111111’) is not a valid SSN
A function to transform a dateString in the form yyyy-mm-dd into a javascript date object. This is necessary because parsing the date string will result in a date one day before the expected value