leaflet-terminator
leaflet-terminator
npm i leaflet-terminator
leaflet-terminator

leaflet-terminator

Displays a solar terminator on a Leaflet map.

by mapbox

0.1.0 (see all)License:ISCTypeScript:Not Found
npm i leaflet-terminator
Readme

leaflet-terminator

Displays a solar terminator on a Leaflet map.

API

terminator(date)

Create a solar terminator. The terminator is a Leaflet L.Path object.

date is optional, and would need to be a JavaScript Date object. Default is now.

terminator.setDate(date)

Recalculate the terminator to a given JavaScript Date object.

Using it

This is built with browserify. If you want a standalone javascript file or UMD module, download leaflet-terminator.js.

If you want to use it with browserify, use npm.

If you have a patch to contribute, change things in index.js or in one of the dependency files. leaflet-terminator.js is a built file, do not change it: your changes will be overwritten.

See Also

This is totally cribbed from Mike Bostock's example, which is itself cribbed from science. Under the hood lie a bunch of libraries that you can use separately, like leaflet-geodesy and spherical.

Downloads/wk

3

GitHub Stars

26

LAST COMMIT

6yrs ago

MAINTAINERS

1

CONTRIBUTORS

2

OPEN ISSUES

3

OPEN PRs

1
VersionTagPublished
0.1.0
latest
8yrs ago
No alternatives found
No tutorials found
Add a tutorial

Rate & Review

100
No reviews found
Be the first to rate