New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-password-strength-bar

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-password-strength-bar

A React component that displays the password strength bar

  • 0.4.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
32K
decreased by-1.33%
Maintainers
1
Weekly downloads
 
Created
Source

react-password-strength-bar

A React component that displays the password strength bar

NPM

Version Build Coverage Status code style: prettier License

Gif

Note

  • This package is based on zxcvbn. zxcvbn is a powerful library, but its size is very large. I recommend you use this package by Code-Splitting.
  • The input tag is not included. If you want to include the input tag, use the mmw/react-password-strength package.

Install

$ npm install react-password-strength-bar
$ yarn add react-password-strength-bar

Usage

import PasswordStrengthBar from 'react-password-strength-bar';

const { password } = this.state;
<PasswordStrengthBar password={password} />

Props

className: string
  • isRequired: false
  • default: undefined
style: object
  • isRequired: false
  • default: undefined
scoreWordClassName: string
  • isRequired: false
  • default: undefined
scoreWordStyle: object
  • isRequired: false
  • default: undefined
password: string
  • isRequired: true
  • default: ''
userInputs: string[]
  • isRequired: false
  • default: []
barColors: string[]
  • isRequired: false
  • default: ['#ddd', '#ef4836', '#f6b44d', '#2b90ef', '#25c281']
scoreWords: ReactNode[]
  • isRequired: false
  • default: ['weak', 'weak', 'okay', 'good', 'strong']
minLength: number
  • isRequired: false
  • default: 4
shortScoreWord: ReactNode
  • isRequired: false
  • default: 'too short'
onChangeScore: (score, feedback) => void
  • isRequired: false
  • default: undefined

Browser support

Tested with modern browsers.

License

the MIT license.

Keywords

FAQs

Package last updated on 05 Jun 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc