react-leaflet-geodesic3

2.0.4 • Public • Published

react-leaflet-geodesic npm version

Draws geodesic curves on React-Leaflet, which are the real minimal "line" between two coordinates of the Earth.

This is a part-wrap of Leaflet.Geodesic, made by henrythasler. There are some code still needed to get all functionalities from his lib, feel free to add it.

Example

Usage

import { GeodesicLine } from 'react-leaflet-geodesic'
...
const waypoints = [
  [-33, -70],
  [-33, 151],
]

const options = {
  weight: 20,
  opacity: 0.5,
  color: 'red',
}
...
<GeodesicLine positions={waypoints} options={options} />
...

For more details on how to use this plugin check the example.

Package Sidebar

Install

npm i react-leaflet-geodesic3

Weekly Downloads

1

Version

2.0.4

License

GPL-3.0

Unpacked Size

201 kB

Total Files

21

Last publish

Collaborators

  • btafel