Replies: 1 comment
-
I find a way with the following:
There's probably a better way than this function:
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I am using a
FieldArray
to display repeatable editable form elements made of several fields.I would like to emphasize whether a given element has been modified (regardless of its modified field).
So I'm looking for a efficient and as generic as possible to evaluate the dirty state of a
FieldEntry
A little illustration:
Is there a equivalent to
useIsFieldDirty
forFieldEntry
to achieve this result?I see useIsFieldDirty relies on a
field.meta.dirty
but I am unsure where I could easily determine the fields that a FieldEntry consists of.Shall I apply
Object.keys
to FieldEntry value to dynamically rebuild the paths of the Fields?Thanks!
Beta Was this translation helpful? Give feedback.
All reactions