Is there a way to make the MyLocation widget stay on so that it will follow you around as you are moving?
-Stan
Solved! Go to Solution.
Stan,
Sure just add "useTracking": true to the locateButton object in the config.json for the myLocate widget.
So the config.json will look like this:
{
"locateButton": {
"geolocationOptions": {
"timeout": 15000
},
"highlightLocation": true,
"useTracking": true
}
}
Stan,
Sure just add "useTracking": true to the locateButton object in the config.json for the myLocate widget.
So the config.json will look like this:
{
"locateButton": {
"geolocationOptions": {
"timeout": 15000
},
"highlightLocation": true,
"useTracking": true
}
}
Thanks Robert I knew there was a parameter to add but I could not find it right off.
Is there a way to toggle this on and off?
William,
Sure you just click the locate button again to turn it off, just like the standard LocateButton dijit in the JS API.