Skip to content

Instantly share code, notes, and snippets.

@sw331
Created December 7, 2016 20:10
Show Gist options
  • Select an option

  • Save sw331/1d20837d358076b34b6a320a0a353ee2 to your computer and use it in GitHub Desktop.

Select an option

Save sw331/1d20837d358076b34b6a320a0a353ee2 to your computer and use it in GitHub Desktop.
var mystyle = {
"color": "#ff7800",
"weight": 5,
"opacity": 0.65
};
function popout(feature, layer) {
layer.bindpopup(`<h1>${feature.properties.name}</h1>\n<h3>${feature.properties.created_at.slice(0, 16)}</h3>\n<h2>${feature.properties.text}</h2>\n<h3>📍${feature.properties.location}</h3>`);
};
l.geojson(geoinfo, {
oneachfeature: popout
}).addto(map);
map.addlayer(mytiles).setview([25.5, -25.0], 3);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment