Improvements 🔥
- Better build output thanks to tsdx v0.6.0
- Rearchitected validation and to make it fully backwards compatible with v1
- Formik now uses the new
scheduler
package to improve performance. Validation now comes in 2 flavors. Validation triggered imperatively (viavalidateForm
orvalidateField
) and prior to submit will run at the default priority (same behavior as before). Formik will now schedule validation that run as a side effect in response to callinghandleChange
,setFieldValue
,setValues
,handleBlur
,setFieldTouched
, orsetTouched
at low-priority. The goal is tell the browser that these validation updates should never block user input (changes to values). Since we are usingscheduler
directly, it's been added to Formik's deps. For power users, you should watch Brandon Dail's React Europe talk aboutscheduler
.
Commits