Validation

Powerful validation for accurate data collection.

Superform provides robust validation mechanisms, integrating both it's advanced validation rules and native HTML validations rules. This ensures your forms are accurate, user-friendly, and efficient.


Supported Validations

Superform abstracts validation controls, seamlessly combining advanced Superform-specific validations with familiar HTML validation attributes for a comprehensive validation strategy.

Here's a breakdown of all the supported validations:

Superform Validations
Native HTML Validations

letters(min, max)

required

minmax(min, max)

pattern

words(min, max)

min

checkbox(min, max)

max

must(number, lower, upper, symbol)

minlength

hook(myHook)

maxlength

min (date)

max (date)

Pro Tips

  • Combined Power: Combine Superform validations with native HTML attributes for robust form validation.

  • Show Errors: Provide immediate feedback to users, guiding them to correct errors quickly. Both Superform-specific and native HTML validations work out of the box with the Error Management system.

  • Flexible Integration: Use custom hook validations for complex validation logic.


List of Superform validation attributes

Last updated