mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
* Leaflet routing machine typing definition implementation :: Tested * strictFunctionTypes set true * Added typescript version * Issue fixes * Issue fixes * Issue fixes * Issue fixes * Issue fixes * Issue fixes
16 lines
398 B
TypeScript
16 lines
398 B
TypeScript
import * as L from 'leaflet';
|
|
import 'leaflet-routing-machine';
|
|
|
|
const map: L.Map = L.map('map-container');
|
|
|
|
L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', {
|
|
attribution: '© <a href="http://osm.org/copyright">OpenStreetMap</a> contributors'
|
|
}).addTo(map);
|
|
|
|
L.Routing.control({
|
|
waypoints: [
|
|
L.latLng(57.74, 11.94),
|
|
L.latLng(57.6792, 11.949)
|
|
]
|
|
}).addTo(map);
|