You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/directions.js
+4-3Lines changed: 4 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -23,9 +23,10 @@ import Instructions from './controls/instructions';
23
23
* @param {Array} [options.styles] Override default layer properties of the [directions source](https://github.com/mapbox/mapbox-gl-directions/blob/master/src/directions_style.js). Documentation for each property are specified in the [Mapbox GL Style Reference](https://www.mapbox.com/mapbox-gl-style-spec/).
24
24
* @param {String} [options.accessToken=null] Required unless `mapboxgl.accessToken` is set globally
25
25
* @param {Boolean} [options.interactive=true] Enable/Disable mouse or touch interactivity from the plugin
* @param {Boolean} [options.alternatives=true] Whether to enable alternatives.
28
28
* @param {String} [options.unit="imperial"] Measurement system to be used in navigation instructions. Options: `imperial`, `metric`
29
+
* @param {Function} [options.compile=null] Provide a custom function for generating instruction, compatible with osrm-text-instructions.
29
30
* @param {Object} [options.geocoder] Pass options available to mapbox-gl-geocoder as [documented here](https://github.com/mapbox/mapbox-gl-geocoder/blob/master/API.md#mapboxglgeocoder).
30
31
* @param {Object} [options.controls]
31
32
* @param {Boolean} [options.controls.inputs=true] Hide or display the inputs control.
@@ -35,7 +36,7 @@ import Instructions from './controls/instructions';
35
36
* var directions = new MapboxDirections({
36
37
* accessToken: 'YOUR-MAPBOX-ACCESS-TOKEN',
37
38
* unit: 'metric',
38
-
* profile: 'cycling'
39
+
* profile: 'mapbox/cycling'
39
40
* });
40
41
* // add to your mapboxgl map
41
42
* map.addControl(directions);
@@ -110,7 +111,7 @@ export default class MapboxDirections {
0 commit comments