JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2
  • Score
    100M100P100Q35991F
  • License MIT

Package Exports

  • passec

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (passec) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

passec

Passec checks the security of the entered passwords, and returns a score.

Installation

npm install passec --save

Usage

var passec = require('passec');
var password = "pass123";

console.log(passec(password))
// 40
var password = "Password00?&";

console.log(passec(password))
// 80

Usage in Register System

var password = req.body.password;
if(passec(password) > 50){ // 50 is recommended
   // do something
}else{
   res.send('Your password is not secure!');
}

Author

rimekod