https://github.com/dcdourado/react-leaflet-geodesic
Geodesic curves as React component for Leaflet
https://github.com/dcdourado/react-leaflet-geodesic
Last synced: 6 months ago
JSON representation
Geodesic curves as React component for Leaflet
- Host: GitHub
- URL: https://github.com/dcdourado/react-leaflet-geodesic
- Owner: dcdourado
- License: gpl-3.0
- Created: 2020-01-28T18:10:29.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-02-03T17:07:47.000Z (over 6 years ago)
- Last Synced: 2024-10-12T04:24:10.889Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 155 KB
- Stars: 3
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-list - react-leaflet-geodesic
README
# react-leaflet-geodesic [](https://www.npmjs.com/package/react-leaflet-geodesic)
Draws geodesic curves on [React-Leaflet](https://github.com/PaulLeCam/react-leaflet), which are the real minimal "line" between two coordinates of the Earth.
This is a part-wrap of [Leaflet.Geodesic](https://github.com/henrythasler/Leaflet.Geodesic), made by henrythasler. There are some code still needed to get all functionalities from his lib, feel free to add it.

# Usage
```
import { GeodesicLine } from 'react-leaflet-geodesic'
...
const waypoints = [
[-33, -70],
[-33, 151],
]
const options = {
weight: 20,
opacity: 0.5,
color: 'red',
}
...
...
```
For more details on how to use this plugin check the example.