Reference · Your sky: altitude and azimuth for a place and a moment
Observertype
Where you stand on Earth, in degrees.
Import it
import type { Observer } from "@johnmorrisdotca/hoshi-stars/sky";
Definition
interface Observer {
latitude: number;
longitude: number;
heightM?: number;
}
Members
| Name | Type | Description |
|---|---|---|
latitude | number | Degrees north of the equator, -90 to 90. |
longitude | number | Degrees east of Greenwich (west is negative). Any finite number; it wraps at 360. |
heightM (optional) | number | undefined | Metres above sea level; checked but not used, because a star is so far away that height changes its direction by nothing you could measure, and the horizon dip is left out. |
Examples
import type { Observer } from "@johnmorrisdotca/hoshi-stars/sky";
const vancouver: Observer = { latitude: 49.28, longitude: -123.12 };
console.log(vancouver.latitude);49.28What it prints (run when this page was built)