Hi I am trying to add custom markers using leaflet and drawing the route using Routing.control. I need to add a variable to markers to, as I need to update one of the marker positions from time to time. I will only ever have 3 marker or waypoints, a start, a 2nd and 3rd. I will probably need to move only the start marker.
The code to add the route which draws the route and adds the default markers is
var route = L.Routing.control({
waypoints: [
L.latLng(my_lat, my_lng),
L.latLng(job_p_lat, job_p_lng),
L.latLng(job_d_lat, job_d_lng)
],show: false, units: 'imperial',
router: L.Routing.mapbox('API KEY HERE')
}).addTo(map);
I have tried q few things not worth showing as did totally nothing. Any advice would be great, thanks
