
Security News
npm Adopts OIDC for Trusted Publishing in CI/CD Workflows
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
another-time
Advanced tools
Another time is a little library which generates a fake date timer.
$ npm install another-time
const { createTimer } = require('another-time')
createTimer().start()
createTimer([options], [onTick = function () {}])
options.secondsPerSecond : Number
Number of seconds that are computed every real second.
options.minutePerSecond : Number
Number of minutes that are computed every real second.
options.hourPerSecond : Number
Number of hours that are computed every real second.
options.hourPerMinute : Number
Number of hours that are computed every real minute.
options.dayPerSecond : Number
Number of days that are computed every real second.
options.dayPerMinute : Number
Number of days that are computed every real minute.
options.dayPerHour : Number
Number of days that are computed every real hour.
options.weekPerSecond : Number
Number of weeks that are computed every real second.
options.weekPerMinute : Number
Number of weeks that are computed every real minute.
options.weekPerHour : Number
Number of weeks that are computed every real hour.
options.weekPerDay : Number
Number of weeks that are computed every real day.
options.monthPerSecond : Number
Number of months that are computed every real second.
options.monthPerMinute : Number
Number of months that are computed every real minute.
options.monthPerHour : Number
Number of months that are computed every real hour.
options.monthPerDay : Number
Number of months that are computed every real day.
options.yearPerSecond : Number
Number of years that are computed every real second.
options.yearPerMinute : Number
Number of years that are computed every real minute.
options.yearPerHour : Number
Number of years that are computed every real hour.
options.yearPerDay : Number
Number of years that are computed every real day.
options.yearPerMonth : Number
Number of years that are computed every real month.
options.initialSecond : Number
Seconds of the initial fake date time.
options.initialMinute : Number
Minutes of the initial fake date time.
options.initialHour : Number
Hour of the initial fake date time.
options.initialDay : Number
Day of the initial fake date time.
options.initialMonth : Number
Month of the initial fake date time.
options.initialYear : Number
Year of the initial fake date time.
options.weekLength : Number
Number of fake days in a fake week.
options.monthDays : Array<Number>
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.
onTick : function (FakeDate)
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
FAQs
Library to create a parallel timeline with delay
We found that another-time demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
Research
/Security News
A RubyGems malware campaign used 60 malicious packages posing as automation tools to steal credentials from social media and marketing tool users.
Security News
The CNA Scorecard ranks CVE issuers by data completeness, revealing major gaps in patch info and software identifiers across thousands of vulnerabilities.