Licence
MIT
Version
1.0.2
Deps
0
Size
3.9 MB
Vulns
0
Weekly
0
random-name
Generate a random name from a list of over 277,000 names
Install
npm i @thomaschaplin/random-name
Usage
ES5
const randomName = require('@thomaschaplin/random-name')
console.log(randomName.randomFirstName()) // thomas
console.log(randomName.randomLastName()) // chaplin
console.log(randomName.randomFullName()) // thomas chaplin
or
const { randomFirstName, randomLastName, randomFullName } = require('@thomaschaplin/random-name')
console.log(randomFirstName()) // thomas
console.log(randomLastName()) // chaplin
console.log(randomFullName()) // thomas chaplin
ES6
import { randomFirstName, randomLastName, randomFullName } from '@thomaschaplin/random-name')
console.log(randomFirstName()) // thomas
console.log(randomLastName()) // chaplin
console.log(randomFullName()) // thomas chaplin