Allow to validate multiple form fields with the same rule

Author: KES777Created Jan 19, 2025Updated Jan 26, 2025
LabelsType: Feature

New feature motivation

We have few fields. We do not know the exact amount of those fields. It would be nice to have the ability to apply the same validation rule to multiple fields:

I have multiple fields with these names:

name="Company[Phone][0][phone]"
name="Company[Phone][1][phone]"
...
name="Company[Phone][n][phone]"

New feature description

It would be nice to be able to define the rule like:

"Company[Phone][][phone]": { ... }

and apply it to every input with the names above.

New feature implementation

Source: jquery-validation/jquery-validation