class
Directions
A class that provides driving direction functionality.
(map, options)Example:
const directions = new mapgl.Directions(map, {
directionsApiKey: 'Your Directions API access key',
});
directions.carRoute({
points: [
[55.2772379, 25.2377810],
[55.2986956, 25.2576546],
],
});
The map instance.
Directions initialization options.
(options)Finds and draws an optimal car route.
Clears the map from any previously drawn routes.
(type, data?)Calls all event listeners with event type
type
Event type
Data transferred to events
(type, listener)Removes event listener registered with
on
Event type
Event handler
(type, listener)Registers event listener
Event type
Event handler
(type, listener)Registers event listener which will be called once
Event type
Event handler
(options)Finds and draws an optimal pedestrian route.
Evented
Event emitter
(type, data?)Calls all event listeners with event type
type
Event type
Data transferred to events
(type, listener)Removes event listener registered with
on
Event type
Event handler
(type, listener)Registers event listener
Event type
Event handler
(type, listener)Registers event listener which will be called once
Event type
Event handler