npm

Ready to take your JavaScript development to the next level? Meet npm Enterprise - the ultimate in enterprise JavaScript. Learn more »

random-age

1.0.2 • Public • Published

random-age

Generate a random age.

MIT License

build:? coverage:?

Install

$ npm install --save random-age 

Usage

var randomAge = require('random-age');
 
// API
// - randomAge();
// - randomAge([options]);

Default range is between 1 and 120:

randomAge();
// => 45

Optionally specify one of a handful of enumerated age types:

randomAge({ type: 'child' });
// => 9

Allowed types are: child, teen, adult, senior.

Related

Contributing

Pull requests and stars are highly welcome.

For bugs and feature requests, please create an issue.

install

npm i random-age

Downloadsweekly downloads

8

version

1.0.2

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability