Product
Introducing License Enforcement in Socket
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
Accurate time for the browser.
<script src="https://cdn.jsdelivr.net/npm/accutime@latest/dist/accutime.min.js"></script>
npm i accutime
const accutime = require('accutime');
npm i accutime
import accutime from 'accutime';
accutime.getTime();
Get the time.
Returns a promise that resolves to:
{
"datetime": "2024-02-01T11:33:36.841Z",
"timezone": "Europe/London",
"utc_offset": "+00:00",
"unix": 1706787216841
}
accutime.ntpJS(timezone: string)
Parameters:
Get the time from https://use.ntpjs.org/v1/time.json.
Returns a promise that resolves to:
[
{
"now": 1706787368.862806,
"backoff": 375,
"__server": "lhrlhr"
},
62
]
The first value in the array is the response from the server.
The second value in the array is the amount of time it took to make the request.
accutime.worldTimeApi(append: string)
Parameters:
https://worldtimeapi.org/api/
. In practise, you can append a timezone or ip
for time at your IP. See the World Time API website for details.FAQs
A JS library that fetches time from multiple sources and returns the time.
The npm package accutime receives a total of 0 weekly downloads. As such, accutime popularity was classified as not popular.
We found that accutime demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Product
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
Product
We're launching a new set of license analysis and compliance features for analyzing, managing, and complying with licenses across a range of supported languages and ecosystems.
Product
We're excited to introduce Socket Optimize, a powerful CLI command to secure open source dependencies with tested, optimized package overrides.