Home > @magiclane/maps-sdk > MapDetails > isNight

MapDetails.isNight() method

Returns whether it is night at the given coordinates and reference time.

Signature:

static isNight(coords: Coordinates, time: Date): boolean;

Parameters

Parameter

Type

Description

coords

Coordinates

WGS84 coordinates

time

Date

Reference time

Returns:

boolean

True if it is night at the specified location/time, false otherwise