DynamicMapLayers don't manage 'Antimeridian artifacts'
See original GitHub issue- Browser and version:
All
- Version of Leaflet (
L.version
):
1.2.0
- Version of esri Leaflet (
L.esri.VERSION
):
2.1.1
Steps to reproduce the error:
- create a DynamicMapLayer with geographic coordinate system data crossing the International Date Line (e.g. polygon data on both sides of the IDL along the Alaskan Aleutian islands).
- display data on map using ESRI Leaflet
What happens is …
You can view the problem by opening our public ESRI Leaflet application @ https://hydromaintenance.nationalmap.gov/hmp. Minimize the login sidebar using the hamburger button then open the layer control in the upper right. Click off all the layers except the last (Hydrologic Units (Hu-4/Hu-8)). Pan and zoom the map to the Alaskan Aleutian islands. You’ll see that the polygon data stops at the International Date Line. As it happens, the map server supplies data on the other side of the line that’s not being translated and displayed correctly.
I was expecting all our data from the map service to be rendered without issue.
There’s a base Leaflet plugin designed to resolve this problem: https://github.com/briannaAndCo/Leaflet.Antimeridian. We’re just missing a solution for DynamicMapLayers, which we use because of the complex rendering we need to apply for our layers. Deconstructing the object itself into GeoJSON to apply the solution offered by this plugin seems to be a misplaced solution if it might be better addressed in the ESRI Leaflet API itself.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (4 by maintainers)
Top GitHub Comments
Actually, no I hadn’t. Thank you! - can you advise or offer any thoughts about what this offers vis-a-vis our problem?
Update: Ok looking at their implementation it seems pretty cut/dry… I’ll give it a shot and see if we get lucky 😃 Thanks for the tip!
no worries at all.