@ddnn55/daylight

Predict the time of sunrise and sunset. Adapted from https://en.wikipedia.org/wiki/Sunrise_equation

Usage no npm install needed!

<script type="module">
  import ddnn55Daylight from 'https://cdn.skypack.dev/@ddnn55/daylight';
</script>

README

daylight

Predict the time of sunrise and sunset. Adapted from https://en.wikipedia.org/wiki/Sunrise_equation

daylight(date, latitude, longitude) ⇒ Object

Predict sunrise and sunset.

Kind: Exported function
Returns: Object - Predicted time of sunrise and sunset

Param Type Description
date Date
latitude Number north/south location; -90 (south pole) to 90 (north pole)
longitude Number east/west location; -180 to 180