Skip to content

Instantly share code, notes, and snippets.

@PankajWorks
Created October 23, 2016 17:45
Show Gist options
  • Save PankajWorks/a149e24414c4299bbde32a62599ab440 to your computer and use it in GitHub Desktop.
Save PankajWorks/a149e24414c4299bbde32a62599ab440 to your computer and use it in GitHub Desktop.
# Add the below code in a paragraph and execute the paragraph
%angular
<!DOCTYPE html>
<html>
<head>
<title>Leaflet Map with Heatmap Demo </title>
<meta charset="utf-8" />
<link
rel="stylesheet"
href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css"
/>
</head>
<body>
<div id="map" style="width: 100%; height: 600px"></div>
<script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"> </script>
<script src="http://leaflet.github.io/Leaflet.heat/dist/leaflet-heat.js"> </script>
<script type="text/plain" src="https://gist.githubusercontent.com/d3noob/8973028/raw/6732ac1250e64c7a0fb2929374866b0656d48a7e/2013-earthquake.js"></script>
<script>
var map = L.map('map').setView([-41.5546,174.146], 10);
mapLink =
'<a href="http://openstreetmap.org">OpenStreetMap</a>';
L.tileLayer(
'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
attribution: '&copy; ' + mapLink + ' Contributors',
maxZoom: 18,
}).addTo(map);
var heat = L.heatLayer(quakePoints,{
radius: 20,
blur: 15,
maxZoom: 17,
}).addTo(map);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment