Closed EliasGcf closed 11 months ago
Good idea - do you have any specific use-cases in mind for this? Just so I can get an idea of how it should behave
Good idea - do you have any specific use-cases in mind for this? Just so I can get an idea of how it should behave
@vantezzen , my use-case is for an array of objects, but I think this feature should allow any registered shape (number, string, etc) and include buttons to add, remove, move up, and down (useFieldArray
allow this)
Visually, something like this:
Just added basic support for arrays, might look into improving the design and adding more advanced features like reordering in the future - otherwise PRs are welcome!
Would be nice to support ZodArray type. React Hook Form has a
useFieldArray
hook to help add, remove, etc.