I decided it was about time I made a web map using Leaflet.
We used a nice dataset of daily Antarctic MODIS imagery from GIBS and implemented an idea for a really simple viewer with date selector.
Why polar focussed?
Because when it comes to web mapping, all seems very simple until you want to use a projection that is not web mercator. So this added a nice, challenging component to the plan.
Here’s a walk through of the features we explored and used.
We were really impressed that Leaflet.Graticule plugin worked beautifully on this projection.
Antarctica is big. So when zooming around the imagery, it’s easy to loose track of where you are. We tried to implement the Leaflet-MiniMap plugin. However, we didn’t have much success in getting this to work. We think it’s an issue with the not using straight forward web mercator, but more investigation is required.
Leaflet-hash is used to retain the current map view when switching between imagery dates.
map.fitBounds()wasn’t working with our polar projection, so Orange Mug had to hack a solution. You can find it here. This isn’t perfect however, because it stops any pan animation.
If you want to look more closely at this pretty simple implementation, head to the repo on GitHub.
In the meantime, I’m continuing to use this project as a way to learn and experiment with Leaflet.
Thanks Orange Mug!