Leaflet.js: A New Toy

Leaflet.js allows you to create beautiful, interactive maps with a high level of customisation. So watch this space for more.

Recently, I have been working on a tool that can replace the VicRoads CrashStats website. The reason this came about is due to the lack of reliability with the Tableau software at the time (it has since been drastically improved). A bonus advantage of utilising the raw data was that now we could generate custom crash reports with the company fonts and a consistent layout automatically.

Crash Report Example
Example of the crash report output

Since the CrashStats website had been updated, I had to go one better. There was an opportunity to allow users to define the area which they would like to search. How often is the whole council area relevant to the task at hand? Now users could refine the results to a better resolution using geospatial coordinates (latitude and longitude). But now I had a problem: how will users define that area?

My solution, although a little clunky, was to invest an hour into learning the basics of Leaflet.js. Users can now define the area by creating a box in the map and then copying the output coordinates into Excel.

Bounding Box Example
Example of the output from Leaflet.js

You can test drive my first attempt at Leaflet.jsĀ here.

You can watch the development of an experimental story map here.