1.0.0 • Published 2 years ago

super-pass-gen.js v1.0.0

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

super-pass-gen.js

Installation

js npm i super-pass-gen.js

Functions

generatePassword({}) // Generates an 8 digit password with letters, numbers and special characters 
generatePassword({ length: 12 }) // Generates a 12 digit password with letters, numbers and special characters
generatePassword({ length: 10, useLetters: false, useSpecialCharacters: true, useNumbers: true }) // Generates a 10 digit password with special characters and numbers
generatePassword({ length: 5, useLetters: true, useSpecialCharacters: false, useNumbers: false }) // genarates a 5 digit password with only letters

Discord.js v14 Code Example

const { SlashCommandBuilder } = require('discord.js');
const { generatePassword } = require('super-pass-gen.js');

module.exports = {
    data: new SlashCommandBuilder()
    .setName('generate-password')
    .setDescription('This command will generate a password.'),
    async execute (interaction) {
        const password = generatePassword({});

        await interaction.reply({ content: `Your Password is: ||${password}||!`, ephemeral: true })
    }
}
1.0.0

2 years ago