<commit_before># Psswrd

Psswrd allows client-sided generation of cryptographically secure random passwords.

## Installation

Download [psswrd.js](https://raw.githubusercontent.com/InMomentum/Psswrd/master/dist/psswrd.js) or the minified version [psswrd.min.js](https://raw.githubusercontent.com/InMomentum/Psswrd/master/dist/psswrd.min.js).

```html
<script type="text/javascript" src="path/to/psswrd.min.js"></script>
```

## Usage

It's easy to use Psswrd. Initiate an object and call its getRandomPassword() method. An error will thrown, if it could not generate a password.

```javascript
const psswrd = new Psswrd();
psswrd.getRandomPassword();
```

An error will thrown, if it could not generate a password.

```javascript
const psswrd = new Psswrd();

try {
    psswrd.getRandomPassword();
}
catch(e) {
    // statements to handle exception
}
```

### Configuration

You are free to override any of the default values before retrieving the password that's being generated by the object.

```javascript
const psswrd = new Psswrd();
psswrd.length = 12;
psswrd.letters = 'AaBaCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz';
psswrd.numbers = '0123456789';
psswrd.special = '!$%@#';
psswrd.getRandomPassword();
```

By default, Passwrd generates cryptographically secure random passwords. This can be changed (although not recommended) by overwriting the default value.

```javascript
const psswrd = new Psswrd();
psswrd.strict = false;
psswrd.getRandomPassword();
```

## Build

Psswrd is built with gulp. Psswrd source lives in src, which gets compiled, bundled and minified into dist/psswrd.js and dist/psswrd.min.js with the help of gulp, gulp-babel, gulp-uglify and gulp-rename.

```bash
npm run build
```

## License

Psswrd is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)<commit_msg>Update documentation with new configuration showcase<commit_after># Psswrd

Psswrd allows client-sided generation of cryptographically secure random passwords.

## Installation

Download [psswrd.js](https://raw.githubusercontent.com/InMomentum/Psswrd/master/dist/psswrd.js) or the minified version [psswrd.min.js](https://raw.githubusercontent.com/InMomentum/Psswrd/master/dist/psswrd.min.js).

```html
<script type="text/javascript" src="path/to/psswrd.min.js"></script>
```

## Usage

It's easy to use Psswrd. Initiate an object and call its getRandomPassword() method. An error will thrown, if it could not generate a password.

```javascript
const psswrd = new Psswrd();
psswrd.getRandomPassword();
```

An error will thrown, if it could not generate a password.

```javascript
const psswrd = new Psswrd();

try {
    psswrd.getRandomPassword();
}
catch(e) {
    // statements to handle exception
}
```

### Configuration

You are free to override any of the default values before retrieving the password that's being generated by the object.

```javascript
const psswrd = new Psswrd({
    length: 12,
    letters: 'AaBaCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz',
    numbers: '0123456789',
    special: '!$%@#'
});

psswrd.getRandomPassword();
```

By default, Passwrd generates cryptographically secure random passwords. This can be changed (although not recommended) by overwriting the default value.

```javascript
const psswrd = new Psswrd({
    strict: false
});

psswrd.getRandomPassword();
```

## Build

Psswrd is built with gulp. Psswrd source lives in src, which gets compiled, bundled and minified into dist/psswrd.js and dist/psswrd.min.js with the help of gulp, gulp-babel, gulp-uglify and gulp-rename.

```bash
npm run build
```

## License

Psswrd is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)
{'fraction_non_alphanumeric': 0.1129075720829965, 'fraction_numerical': 0.0064672594987873885, 'mean_word_length': 4.9297124600638975, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1582471', 'n_tokens_mistral': 1325, 'n_tokens_neox': 1243, 'n_words': 370}