Open
Description
The object fieldErrors: Partial<Record<keyof Values, NonEmptyArray<FieldError>>>
returned by useFormo
is not properly cleaned up after each submit of the form: if it contained a key foo
with some validation error after such error is resolved the key is not removed from the object, instead, its value is set to undefined
.
As a consequence using Object.keys(fieldErrors).length > 0
to detect if there is any validation error gives false positives.
Metadata
Metadata
Assignees
Labels
No labels