Skip to content
This repository was archived by the owner on Dec 16, 2025. It is now read-only.
This repository was archived by the owner on Dec 16, 2025. It is now read-only.

Form validator should support variadic/dynamic/unknown size structures #59

@sanjarcode

Description

@sanjarcode

Many form validators around web apps are limited to zero-order logic behavior.
i.e. you need to give a determined and finite number of fields.
This is enough for many situations, yes.

But when it comes to "variadic forms", i.e. a list of line items in an online bill you're creating, each item has many fields to validate.

  • The "app code" needed for a "zero order" validator to work a variadic feature/form is just nuts.
  • Prefilling is hard
  • Usually in such forms, there's good-to-have validation too, possibly connected to some sanity/recommendation API. guessing this one.
  • Re-render time becomes noticeable here, since initial value is changing. One workaround is to add a loading state for form/per-field, but it leads to flickering. Had to keep a "isFormReady" variable.

And since it's UI, the rendering layer makes the problem worse.
The validators need to support dynamic size too, since items may be added, deleted, or order may be changed in the list.

--

Action: find out if there are validator solutions that have first-class support for variadic forms.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions