react-password-strength-bar icon indicating copy to clipboard operation
react-password-strength-bar copied to clipboard

custom score

Open ilyasjinia opened this issue 2 years ago • 1 comments

How we can set our logic to generate custom score?

ilyasjinia avatar May 05 '23 12:05 ilyasjinia

Seems like userInputs allows a bit of customizability. For example, to prevent the user from choosing a password that matches their username, you could pass their username or any other forbiddenWords to the userInputs:

<PasswordStrengthBar password={password} userInputs={[username, ...forbiddenWords]} />

However, this is not a general solution to custom scoring.

mosofsky avatar Oct 25 '23 15:10 mosofsky