Skip to the content

Hoshi Stars星

The stars you can see without a telescope, with names, colours and distances; the 88 constellations with their lines and boundaries; the Messier objects; and seven map projections to draw them on.

Hoshi is the Japanese word 星 for a star. About the name

Contents

Reference · What you can see tonight: the stars above the horizon of a place and a moment that the Sun's light, the sky's darkness and the air still let through, with the twilight, each star's altitude and azimuth and how easy it is to see

sunAltitudefunction

The Sun's altitude over a place at a moment, in degrees (geometric: the centre of the disc, no refraction).

Import it

import { sunAltitude } from "@johnmorrisdotca/hoshi-stars/tonight";

Definition

function sunAltitude(observer: Observer, when: When): number

Parameters

NameTypeDescription
observerObserver

Latitude north and longitude east in degrees.

whenWhen

The moment, a Date or milliseconds since 1970.

Returns

number

Degrees above the horizon, negative when the Sun is down.

Examples

import { sunAltitude } from "@johnmorrisdotca/hoshi-stars/tonight";

// midnight in Vancouver in November: the Sun is far below the horizon
console.log(sunAltitude({ latitude: 49.28, longitude: -123.12 }, Date.UTC(2026, 10, 8, 8)) < -18);
true

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/hoshi-stars 0.47.0.