random-millisecond
v1.0.4
Published
Generate a random millisecond.
Downloads
585
Maintainers
Readme
random-millisecond
Generate a random millisecond.
Install
$ npm install --save random-millisecond
Usage
var randomMillisecond = require('random-millisecond');
// API
// - randomMillisecond([options]);
// options
// - min
// - max
By default, returns a minute from 0
to 999
. Idea is for generating a clock time.
randomMillisecond();
// => 379
Optionally specify min, max, or both to limit the range.
randomMillisecond({ min: 100 });
// => 188
randomMillisecond({ max: 400 });
// => 235
randomMillisecond({ min: 100, max: 400 });
// => 324
Related
- random-year - Generate a random year.
- random-month - Generate a random month.
- random-day - Generate a random day of a month.
- random-hour - Generate a random hour.
- random-minute - Generate a random minute.
- random-second - Generate a random second.
- random-weekday - Generate a random weekday.
- random-datetime - Generate a random date.
- random-ampm - Return am or pm. Very simple.
- random-timestamps - Generate a timestamp.
- random-hammertime - Generate a random hammertime.
Contributing
Pull requests and stars are highly welcome.
For bugs and feature requests, please create an issue.