Leaflet

an open-source JavaScript library
for mobile-friendly interactive maps

← Back to the list of blog posts

Announcing Leaflet 1.0-rc1

Posted on 18 April 2016 by Iván Sánchez

The road to Leaflet 1.0 continues - we’re proud to get the first release candidate for 1.0 into the wild.

Leaflet 1.0-rc1 closes down on edge cases and API inconsistencies that were present in beta2. The full list of changes is in the 1.0.0-rc1 changelog) as usual, with about 50 bugfixes and a dozen improvements and minor API changes.

Notable changes

Changes in the API documentation

The API documentation is now generated from docstrings, thanks to a new tool dubbed 🍂doc (or “leafdoc”).

Previously, the API documentation was edited manually. This involved a lot of copy-pasting and - over time - bits of code started not to match the documentation.

Most complex software projects use some form of docstrings and tools like JavaDoc, NaturalDocs or JSdoc to convert the docstrings into webpages.

But the documentation for Leaflet requires a few special bits - docstrings cover methods and properties, but they do not cover options nor events, and we wanted to maintain the current look and feel of the documentation. 🍂doc was then born to overcome these limitations.

Leaflet uses class inheritance quite extensively, and the old documentation was sometimes not clear about it. Some users struggled to find the available methods for some of the classes, and inherited options were sometimes mentioned, sometimes not. 🍂doc fixes this by including the documentation of all inherited methods/options/events/properties, collapsed by default:

Collapsed inheritances for L.Polygon

The build system now builds a HTML file with the API docs alongside the minified leaflet.js file. Documentation will be updated on every release based on that file, and pull requests to the gh-pages branch to fix the documentation will be automatically rejected.

Get the release candidate

As with previous releases, you can use our CDN:

<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v1.0.0-rc.1/leaflet.css" />
<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-rc.1/leaflet.js"></script>

A non-minified version of the javascript file is also available as:

<script src="http://cdn.leafletjs.com/leaflet/v1.0.0-rc.1/leaflet-src.js"></script>

The release is also available through NPM (npm install leaflet@rc), GitHub download, and CDN download. We discourage using Bower.

The team in person

This Release Candidate leapt forward when most of the Leaflet team met in Madrid for a weekend to fix bugs and discuss architectural decisions, and whether some big features should make it to 1.0 or be postponed.

This photograph might have been digitally altered to include somebody who couldn't come to Madrid that weekend.
The Leaflet team in Madrid
Iván and Yohan want to extend a special thanks to the roll of toilet paper.
The Leaflet team in Madrid

We enjoyed meeting in person and fighting bugs together. It proved to be a very productive thing to do, as about 20 issues were closed that day. Hopefully another in-person meeting will happen soon, with another release!

We hope you enjoy Leaflet 1.0-rc1 as much as we did coding it!

Best, Iván & Vladimir & Yohan & Per & Zsolt.