Has anyone made the Esri Leaflet Vector map rotate? E.g. using a laptop in a vehicle that "up" on the map would be the direction that the car is facing.
I tried combining demo code from Esri and from the leaflet-rotate-map plug-in (https://www.npmjs.com/package/leaflet-rotate-map) but this has problems. For example a 45 degree rotation on this view:
does rotate but it loses some of the map area and also the marker is no longer at the same point on the ground.
Are there any known ways for doing rotation with Esri Leaflet Vector?
Solved! Go to Solution.
Per this issue in the Leaflet repository, Leaflet does not officially support rotation. If you're looking for map rotation, I would suggest looking at the ArcGIS API for JavaScript v4 which fully supports rotation.
Per this issue in the Leaflet repository, Leaflet does not officially support rotation. If you're looking for map rotation, I would suggest looking at the ArcGIS API for JavaScript v4 which fully supports rotation.
Thanks, Gavin. Leaflet core does not support rotation, but the recent leaflet plugin that I mentioned looks promising; it was published 5 months ago (the Leaflet repository entry you linked to ended in 2018), so I'm hopeful that it will work with some of our current formats. We already have long usage with leaflet and users with various data formats, not just Esri formats, so switching or adding renderers is a big investment.