final-form / react-final-form-arrays

A component for rendering and editing arrays 🏁 React Final Form
MIT License
205 stars 70 forks source link

Meta.active and meta.touched always undefined? #175

Open mmoo opened 2 years ago

mmoo commented 2 years ago

Are you submitting a bug report or a feature request?

A bug report

What is the current behavior?

Looks like the props meta.active and meta.touched of FieldArrayRenderProps are always undefined. To reproduce please open the sandbox and do anything with the fields. https://codesandbox.io/s/react-final-form-field-arrays-forked-ebtzy0

What is the expected behavior?

Not sure I'm getting it right from the docs but I would assume meta.active to be true if one of the fields in the array is active. Also, meta.touched could mean that at least one of the fields has been touched. Alternatively, I'd expect these props to contain arrays of all the fields' corresponding meta values. What I didn't expect is them being undefined all the time.

Sandbox Link

https://codesandbox.io/s/react-final-form-field-arrays-forked-ebtzy0

What's your environment?

    "final-form": "4.20.1",
    "final-form-arrays": "3.0.2",
    "react": "16.8.6",
    "react-dom": "16.8.6",
    "react-final-form": "6.5.3",
    "react-final-form-arrays": "3.1.4",

Other information