As Riku explains in his comment below, there is some repetitive code in formulas.
"I saw a lot of repetitiveness like touched.email && errors.email in every form field. I experienced little bit and found out how to make function that return true or false for given field (email, username etc).
type fieldKeys = keyof typeof values
const checkIfTouchedAndErrors = (fieldName: fieldKeys): boolean =>
!!(touched[fieldName] && errors[fieldName])
If you wan't to make this change it can be used like this checkIfTouchedAndErrors('email')"