Set enableHighAccuracy in geolocation example

This commit is contained in:
Frederic Junod
2018-01-26 09:39:25 +01:00
parent c2f7baf940
commit 819ddd0e19
2 changed files with 6 additions and 0 deletions

View File

@@ -34,6 +34,10 @@ const map = new Map({
});
const geolocation = new Geolocation({
// enableHighAccuracy must be set to true to have the heading value.
trackingOptions: {
enableHighAccuracy: true
},
projection: view.getProjection()
});