Skip to content

jahids/Form-validation-libraries

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Validator - Lightweight & Easy simple HTML form Validator

The Validator is cross-browser and will give you the power to use future-proof input types such as:
first-name, last-name, email, phone url and https.

how to use form validation

// usage this Cdn:  <script src="https://cdn.jsdelivr.net/gh/jahids/Form-validation-livery/build/main.bundle.js"></script>

// usage config code :  new testLibrary.default(document.getElementById('form'), {
  'first-name': { minLength: 2, nonNumeric: true },
  'last-name': { minLength: 3, nonNumeric: true },
  'my-email': { minLength: 5 },
  'phone': { minLength: 11, maxLength: 12 },
  'password': { hasUpperCase: true, hasLowerCase: true },
  'url': { hasHttps: true }
})

// You can show eror message you can use this html code
   <small id="first-name"  class="small"> </small>

Why should you use this?

  • every browser support validation
  • Flexible error messaging system
  • Light-weight this livery

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors