pokemon-username-generator
v1.0.2
Published
Generate random username based on pokemon
Downloads
20
Maintainers
Readme
Pokemon Username Generator
A simple NPM package that generates usernames based on pokemon.
Installation
npm install pokemon-username-generator
Defined dictionaries
- adjetives
- characters
- colors
- items
- pokemons
- regions
- types
settings
Default settings
{
dictionaries: ['regions', 'adjetives', 'pokemons'],
separator: '-',
casing: 'lower',
spaces: false,
}
- dictionaries: list of any defined dictionaries, see custom dictionaries
- separator: string to use as separator
- casing: 'upper', 'lower', 'capital', 'word'
- spaces: keep/create spaces between dictionary word
Usage
const generate = require('pokemon-username-generator')
const generatedUsername = generate(settings)
Custom Dictionaries
To use custom dictionary, should add the dictionary name in dictionaries list and a custom property. Example:
const generatedUsername = generate({
dictionaries: ['colors', 'names', 'regions'],
custom: {
'names': ['Name 1', 'Name 2', 'Name 3']
}
})