Another time is a little library which generates a fake date timer.
$ npm install another-time
const { createTimer } = require('another-time')
createTimer().start()
Number of seconds that are computed every real second.
Number of minutes that are computed every real second.
Number of hours that are computed every real second.
Number of hours that are computed every real minute.
Number of days that are computed every real second.
Number of days that are computed every real minute.
Number of days that are computed every real hour.
Number of weeks that are computed every real second.
Number of weeks that are computed every real minute.
Number of weeks that are computed every real hour.
Number of weeks that are computed every real day.
Number of months that are computed every real second.
Number of months that are computed every real minute.
Number of months that are computed every real hour.
Number of months that are computed every real day.
Number of years that are computed every real second.
Number of years that are computed every real minute.
Number of years that are computed every real hour.
Number of years that are computed every real day.
Number of years that are computed every real month.
Seconds of the initial fake date time.
Minutes of the initial fake date time.
Hour of the initial fake date time.
Day of the initial fake date time.
Month of the initial fake date time.
Year of the initial fake date time.
Number of fake days in a fake week.
List of number of fake days inside fake months. Each item is a number of fake days, fake months don't have names, they are just represented by the index in the array.
Callback to call each real second, the first and only argument is the fake date object containing the structure of the fake date, for example :
{
"second": 2,
"minute": 10,
"hour": 5,
"day": 1,
"month": 12,
"year": 2020
}
This software is released under the GPL-v3.0 License. See LICENSE