Skip to content

Instantly share code, notes, and snippets.

@nbumbarger
Created December 11, 2015 19:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nbumbarger/52d00519295b64bc1d9a to your computer and use it in GitHub Desktop.
Save nbumbarger/52d00519295b64bc1d9a to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>Convex Hull</title>
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' />
<script src='https://api.mapbox.com/mapbox.js/v2.2.3/mapbox.js'></script>
<link href='https://api.mapbox.com/mapbox.js/v2.2.3/mapbox.css' rel='stylesheet' />
<style>
body { margin:0; padding:0; }
#map { position:absolute; top:0; bottom:0; width:100%; }
</style>
</head>
<body>
<div id='map'></div>
<script>
L.mapbox.accessToken = 'pk.eyJ1IjoibmJ1bWJhcmciLCJhIjoiWG1NN1BlYyJ9.nbifRhdBcN1K-mdtwwi0eQ';
var geojson = {"type":"Feature","geometry":{"type":"Polygon","coordinates":[[["-7.3447057","12.1935965"],["-7.9449139","12.5931440"],["-7.9449123","12.5931991"],["-7.8447057","13.5935965"],["-7.4447494","12.7935954"],["-7.3447057","12.1935965"]]]},"properties":{}}
L.mapbox.map('map', 'mapbox.streets')
.setView([12.5933971,-7.9439081], 15)
.featureLayer.setGeoJSON(geojson);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment