jaredpalmer / formik

Build forms in React, without the tears 😭
https://formik.org
Apache License 2.0
33.97k stars 2.79k forks source link

Breaking change in Formik validate v2 #2167

Open gwn opened 4 years ago

gwn commented 4 years ago

📖 Documentation

Validate function is not accepting rejected promises of errors, as it did in v1. I was going to report this as a bug, but this looked intentional to me after checking out the code:

https://github.com/jaredpalmer/formik/blob/9316a864478f8fcd4fa99a0735b1d37afdf507dc/packages/formik/src/Formik.tsx#L190-L206

So if this is intentional, it needs to be documented among other breaking changes (which atm is not): https://github.com/jaredpalmer/formik/blob/master/docs/migrating-v2.md#breaking-changes

If not, needs to be fixed.

Related issue from v1: https://github.com/jaredpalmer/formik/issues/966

jaredpalmer commented 4 years ago

Yeah. Shit, I guess this is breaking after we stopped swallowing the errors in recent releases. can you add to the migration docs?

gwn commented 4 years ago

Sure, I will.

jaredpalmer commented 4 years ago

Thanks!