Reference · The same, with suncalc 1's conventions (radians, azimuth from south)
addTimefunction
Add a time to the ones getTimes gives: when the Sun reaches an altitude in degrees.
Import it
import { addTime } from "@johnmorrisdotca/wakusei-planets/suncalc/legacy";
Definition
function addTime(angle: number, riseName: string, setName: string): void
Parameters
| Name | Type | Description |
|---|---|---|
angle | number | The altitude in degrees. |
riseName | string | The name when the Sun goes up through it. |
setName | string | The name when the Sun goes down through it. |
Examples
import { addTime, times } from "@johnmorrisdotca/wakusei-planets/suncalc/legacy";
addTime(-4, "morningBlue", "eveningBlue");
console.log(times.some((row) => row[1] === "morningBlue"));trueWhat it prints (run when this page was built)