HTML - Form Validation

1 - About

form validation.

3 - List of validation rules

  • required
  • min
  • max
  • minLength
  • maxLength
  • pattern
  • validate

4 - Limitations

HTML validation has its limitations.

  • it only works in the browser (not React Native, …)
  • it's hard/impossible to show custom error messages to our user.

5 - Function

  • form.checkValidity() - Returns true if the form's controls are all valid; otherwise, returns false.
  • form.reportValidity() - Returns true if the form's controls are all valid; otherwise, returns false and informs the user.

6 - Documentation / Reference


Data Science
Data Analysis
Statistics
Data Science
Linear Algebra Mathematics
Trigonometry

Powered by ComboStrap