🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

sunrise-js

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sunrise-js

A way to determine when the sun will rise and set based on your latitude/longitude

0.1.6
latest
Source
npm
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

sunrise-js

Based on the sunrise equation calculates a Javascript UTC Date approximating when sunrise and sunset will happen based on a specified latitude, longitude and Javascript Date.

Largely inspired by the rust-sunrise crate.

Usage

const twilight = require('sunrise-js');
const { sunrise, sunset } = twilight(
    { latitude: 0, longitude: 0 },
    new Date('2023-02-10')
);

Keywords

sunrise

FAQs

Package last updated on 22 Jan 2023

Did you know?

Socket

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.

Install

Related posts