1.0.6 • Published 6 years ago

validationhelper-password v1.0.6

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

validationHelper-password npm GitHub

a validation package for Node.js. Main function is providing different level of password validation.

Installation and Usage

Install

npm install --save validationhelper-password

Usage

const validationHelper = require('validationhelper-password');

Example

let value = 'abc';
console.log((validationHelper.isEmpty(value)))//=>false;


let password = '111112A';
let min = 2;
let max = 10;
console.log(validationHelper.passwordQuality.isLowQuality(password,min,max))//=>true;

Function

All function are listed below:

ValidationDescription
isEmpty(parameter)check if the parameter is empty.
isLowQuality(password, min, max)check if the password contains at least one of number, uppercase letter or lowercase letter. (1a, 1A, aA)
isHighQuality(password, min, max)check if the password contains at least one number, one uppercase letter, one lowercase letter. (1aA)
isSuperQuality(password, min, max)check if the password contains at least one number, one uppercase letter, one lowercase letter and one symbol. (1aA#)
isTime(time)check if the time format is HH:mm. (23:00)
isDate(date)check if the date format is YYYY-MM-DD. (2018-10-20)

Contributing

In general, this project follow the "fork-and-pull" Git workflow.

  1. Fork the repo on GitHub
  2. Clone the project to your own machine
  3. Work on your fork
    1. Make your changes and additions
    2. Change or add tests if needed
    3. Add changes to README.md if needed
  4. Commit changes to your own branch
  5. Push your work back up to your fork
  6. Submit a Pull request and waiting to be accepted

License (MIT)

License

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago