perliedman / leaflet-routing-machine

Control for routing in Leaflet
https://www.liedman.net/leaflet-routing-machine/
Other
1.08k stars 350 forks source link

Leaflet Routing Machin ,leaflet-routing-container without data there #576

Closed FabienRakoto closed 4 years ago

FabienRakoto commented 4 years ago

Hi there,

Can someone help me, i try to integrate Leaflet Routing Machine on ionic an i have some issue, @perliedman this is my code

` showMap(){ this.map = new Map('maps').setView([-18.8915482,47.508515],10); tileLayer('http://{s}.tile.openstreetmap.fr/osmfr/{z}/{x}/{y}.png', { attribution: '© Open Street Map', zoom: 8, maxZoom: 18, minZoom: 4, minResolution: 4891.96981025128, maxResolution: 39135.75848201024, doubleClickZoom: true, center:this.latlng }).addTo(this.map);

    L.Routing.control({
      waypoints: [
        L.latLng(57.74, 11.94),
        L.latLng(57.6792, 11.949)
      ]
    }).addTo(this.map);

} `

perliedman commented 4 years ago

Sorry, no way for me to debug code without stack trace, error message or running example.

In this particular case, I would guess it does not work since the demo server that LRM's defaults rely on no longer available. You need to find another server unfortunately.