I have a Formik form in react native and a Yup validationSchema. When user submits form I want to create an alert with the error fields if there are fields that are invalid.
Dependencies:
"formik": "^1.4.1",
"react": "16.5.0",
"react-native": "0.57.1",
I have tried using isValid inside the Formik render and create an Alert with errors, but I get an empty errors object. However if I submit again/or click submit twice, the error object contains the invalid fields as expected.
How can I get the errors object on first submit?