Advanced Interactive Web Mapping, Programming, and Design

In-class Excercises: Git and GitHub

Part 1: Leaflet map events

  1. Open this Leaflet map that searches using Mapzen Search.
  2. Add an event handler to the map for one of the events listed in the docs. You can do whatever you like when the event occurs. At the very least, use console.log() to prove that the event listener worked.

Part 2: Leaflet path events

  1. Leave the map open from part 1.
  2. Add a click handler to the features for one of the events listed in the docs for paths. This jsbin might be helpful. When the feature is clicked, try calling the getStreetview function with the latitude and longitude to show streetview for that point.