Skip to content

Introduce bulk mode and few optimisations

Compare
Choose a tag to compare
@SMAKSS SMAKSS released this 19 Nov 13:52
· 1 commit to main since this release

Release Notes for Password Generator - Version 3.0.0

🌟 Overview

We are excited to announce the release of version 3.0.0 of the Password Generator package. This update introduces enhanced usability, new features, and improved naming conventions for better clarity and consistency.

πŸš€ What's New

  • String Input for Custom Characters: The characters option now accepts a string instead of an array, simplifying the way users can input custom characters for password generation.
  • Bulk Password Generation: Introducing the numberOfPasswords parameter, allowing users to generate multiple passwords at once. This feature is perfect for creating a set of passwords in one go.
  • Improved Parameter Names: Updated parameter names for enhanced clarity:
    • Renamed lowerIncluded, capsIncluded, numIncluded, and specIncluded to includeLower, includeCaps, includeNums, and includeSpecs respectively, aligning the naming convention.

πŸ“ Migration Guide

To upgrade to the new version, please consider the following changes:

  • Update the characters parameter to pass a string instead of an array.
  • Utilize the numberOfPasswords parameter for generating multiple passwords.
  • Adjust your function calls to align with the new parameter names if you were using the older ones.

πŸ” Examples of Usage

Generate a Single Password

const password = PasswordGenerator({ length: 10, includeNums: true });
console.log(password);  // Outputs a 10-character password with numbers

Generate Multiple Passwords

const passwords = PasswordGenerator({ numberOfPasswords: 5 });
console.log(passwords);  // Outputs an array of 5 random passwords

Using Custom Characters

const password = PasswordGenerator({ length: 10, characters: 'abc123' });
console.log(password);  // Outputs a password using only 'abc123'