Leaflet author here! Just wanted to note that if you haven't looked into OpenLayers in a few years, you absolutely should — it's astonishing how much it progressed: from something that I was so frustrated with that it prompted me to write Leaflet in the first place (11 years ago) to a modern, fast, well-engineered and lovingly maintained library.
It's especially great when you're doing complex GIS stuff and need a ton of features and formats supported out of the box. As for other libraries, I'd recommend Leaflet for simple maps, and Mapbox GL for rich, highly interactive apps that benefit from vector rendering tech (I'm biased since I contributed to both), but it's great to have OpenLayers in the mix — there's a library for anyone's needs, cross-inspiration moves all three forward, and the mapping software landscape in general is greater than it has ever been.
Thank you for building leaflet. It (and scrapy) are how I wound up finding the house I live in now - a quirky, dirt cheap cottage I'd never have taken note of without the tools to filter and visualize a whole country's listings.
Thank you so much for all the work you put into creating and maintaining Leaflet. It’s pretty remarkable how much time and energy you (and others, of course) put into making something so complex so intuitive.
When compared to the other two major OSS libraries I would say:
- Leaflet. Widely known, suitable for mostly simple use cases.
- Mapbox GL JS. State of the art library based on WebGL. Mapbox started off with a fork/extension of Leaflet called Mapbox.js but over time has moved on and created the Mapbox GL JS library from the ground up. Very fast, but requires a GPU due to WebGL.
- OpenLayers. Often used by more professional users. Probably the most features complete library. Also usable without a GPU.
Speaking of, does anyone know a cheaper service than Mapbox and Google Maps for raster tiles?
I have an app that uses Leaflet for rendering, and Mapbox purely for its raster tiles (both plain maps and satellite required). Mapbox has been cheap for us, at about $50/mo. But with the new pricing structure taking effect in December, it's now about $450/mo. I believe Google and Bing are both more expensive than that.
I've been considering setting up OSM, but I'd like to avoid having to run and maintain it.
If you can find the time to set it up, OpenMapTiles [0] is the way to go. In the long run, you’ll probably save more money than the time it takes to manage.
We are hosting about 150GB of map data, raster and vector, with the following stack:
- MapProxy with Redis cache
- MapServer for rendering
- PostGIS for data storage
I went through the various providers and ended up using MapTiler Cloud, it is the cheapest option I know of besides generating and serving your own tiles.
Joe here from the Mapbox billing support team. Feel free to reach out to help@mapbox.com. We can dig into your implementation with you to see if there are ways to limit your API consumption (and reduce your overall bills).
Things like limiting panning/zooming can help limit the number of tiles your end users load. Fewer tiles -> cheaper invoices
I'm in a similar boat, looking to generate my own vector tile static images (basically raster tiles with fractional zoom levels). I use a fair amount of these, and there's no service that lets you cache them (of course). Seems like Mapbox and Maptiler are the only games in town.
OpenLayers was one of the first open source libraries of this kind; sadly it's lost some development momentum back when everyone was using it in 2008 or so, and nearly everyone switched to (then faster) alternatives like Leaflet.
We use OpenLayers extensively in my company (https://www.podaris.com), and we push it really, really hard. It's the basis for a parametric CAD system, a bunch of GIS tools, and most recently, transport micro-simulation. It had a steep learning curve, but has held up remarkably well over the years, with remarkably few instances where it's been the bottleneck.
We had the exact opposite problem! We built a custom webgl rendering layer on top of leaflet to get around leaflet's performance issues. We have now switcher to openlayers and very happy. Guess it depends on the exact use case.
Some time ago I checked out three libraries for my amateur small navigation app:
Leaflet - it doesn't have map rotation, so it was a dealbraker for me. People on Stack Overflow were talking about ugly hacks, I didn't want to go into the rabbit hole.
Mapbox - I found docs little clunky (again, I'm amateur so it may be the reason I didn't get it) and couldn't really work out what's paid and what's free. Didn't spend a lot of time on them, though.
OpenLayers - I think it's the best one feature-wise, but documentation is rather for more advanced developers. I struggled a lot before finally grasping how it works and still, it's not easy. Getting started guide like Vue.js has would be immensely helpful.
I ended up with OpenLayers and I'm pretty satisfied for now, despite needing fairly long time to actually implement features properly.
What a coincidence! I discovered OpenLayers yesterday when looking for a way to display a 1 Terapixel image. I got it up and running in a few hours. Kudos to the developers!
I like OpenLayers. We built a rather complex image annotation tool around it and OpenLayers worked well with all the features we added over the years, recently even a full-blown video annotation tool. The community is nice and active, too. Best of all: It's still compatible with our old school way of JS development. The only thing I'm missing is the API documentation of older versions which they seem to have dropped at some point.
We use OpenLayers at our company. We are building an interactive map with a bunch of tools for measuring distance, calculating routes, drawing features, displaying diagrams right on top of the map, and OpenLayers is doing wonders for us. It has a steep learning curve but once you grasp the fundamentals, you can figure out how to do all kinds of magic tricks with it.
What is the advantage of having the documentation CC-BY 3.0 licensed ? In cases where documentation is generated from the code it seems more convenient to use the same license for both.
I used OpenLayers back in 2008-2011 for mapping-heavy web application. It was of very high quality, and had great API documentation (using DoxyGen, iirc). Taught me some things about pre-modern-craze Javascript programming (i.e. how to correctly implement inheritance in JS)
mourner|6 years ago
It's especially great when you're doing complex GIS stuff and need a ton of features and formats supported out of the box. As for other libraries, I'd recommend Leaflet for simple maps, and Mapbox GL for rich, highly interactive apps that benefit from vector rendering tech (I'm biased since I contributed to both), but it's great to have OpenLayers in the mix — there's a library for anyone's needs, cross-inspiration moves all three forward, and the mapping software landscape in general is greater than it has ever been.
guu|6 years ago
Do you have any specific examples of "complex GIS stuff" (Uses OpenLayers) or a "highly interactive app" (Uses MapBox GL)?
Are there any big feature gaps from leaflet->mapbox-gl that developers should consider when choosing a mapping library?
CalRobert|6 years ago
ughitsaaron|6 years ago
iguessthislldo|6 years ago
conroydave|6 years ago
rickette|6 years ago
- Leaflet. Widely known, suitable for mostly simple use cases.
- Mapbox GL JS. State of the art library based on WebGL. Mapbox started off with a fork/extension of Leaflet called Mapbox.js but over time has moved on and created the Mapbox GL JS library from the ground up. Very fast, but requires a GPU due to WebGL.
- OpenLayers. Often used by more professional users. Probably the most features complete library. Also usable without a GPU.
giancarlostoro|6 years ago
baroffoos|6 years ago
atombender|6 years ago
I have an app that uses Leaflet for rendering, and Mapbox purely for its raster tiles (both plain maps and satellite required). Mapbox has been cheap for us, at about $50/mo. But with the new pricing structure taking effect in December, it's now about $450/mo. I believe Google and Bing are both more expensive than that.
I've been considering setting up OSM, but I'd like to avoid having to run and maintain it.
bransonf|6 years ago
[0] https://openmaptiles.org/
sciurus|6 years ago
lukeqsee|6 years ago
https://stadiamaps.com
Happy to answer any questions! (I’m a cofounder.)
CalRobert|6 years ago
ruffrey|6 years ago
mdasen|6 years ago
Stadia Maps is pretty cheap. $25 gets you 25,000 map views per day or around 750k/month. $100 gets you 250k/day or around 7.5M per month.
Shakahs|6 years ago
https://www.maptiler.com/cloud/plans/
joe-mapbox|6 years ago
Joe here from the Mapbox billing support team. Feel free to reach out to help@mapbox.com. We can dig into your implementation with you to see if there are ways to limit your API consumption (and reduce your overall bills).
Things like limiting panning/zooming can help limit the number of tiles your end users load. Fewer tiles -> cheaper invoices
https://docs.mapbox.com/mapbox.js/example/v1.0.0/maxbounds/
There are other options as well. That said, it's hard to know exactly without taking a look at your map specifically. Let us know!
roelschroeven|6 years ago
Their website is quite confusing though, if you ask me. A starting point might be https://developer.here.com/sign-up?create=Freemium-Basic&kee...
durkie|6 years ago
geuis|6 years ago
andrewshadura|6 years ago
jackinloadup|6 years ago
nkoren|6 years ago
Definitely recommended!
maliker|6 years ago
zefman|6 years ago
k__|6 years ago
Demiurge|6 years ago
pkalinowski|6 years ago
Leaflet - it doesn't have map rotation, so it was a dealbraker for me. People on Stack Overflow were talking about ugly hacks, I didn't want to go into the rabbit hole.
Mapbox - I found docs little clunky (again, I'm amateur so it may be the reason I didn't get it) and couldn't really work out what's paid and what's free. Didn't spend a lot of time on them, though.
OpenLayers - I think it's the best one feature-wise, but documentation is rather for more advanced developers. I struggled a lot before finally grasping how it works and still, it's not easy. Getting started guide like Vue.js has would be immensely helpful.
I ended up with OpenLayers and I'm pretty satisfied for now, despite needing fairly long time to actually implement features properly.
ghgr|6 years ago
degenerate|6 years ago
https://openlayers.org/en/latest/examples/static-image.html
mzur|6 years ago
moonfleet|6 years ago
nkoren|6 years ago
herogreen|6 years ago
n1vz3r|6 years ago
kls|6 years ago
nickik|6 years ago
widforss|6 years ago
jascii|6 years ago