Skip to content

Commit

Permalink
rm extra node_modules, reorganize
Browse files Browse the repository at this point in the history
  • Loading branch information
ianalexmac committed May 8, 2024
1 parent cc90abd commit 40383bd
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 1,267 deletions.
17 changes: 1 addition & 16 deletions code/heatmap.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ var map = new mapboxgl.Map({
});


fetch('/data/api_output.json')
fetch('data/api_output.json')
.then(response => response.json())
.then(data => {
const geojsonData = convertToGeoJSON(data);
Expand Down Expand Up @@ -74,18 +74,3 @@ fetch('/data/api_output.json')
});
});




// old point layer from JSON
// fetch('../data/api_output.json')
// .then(response => response.json())
// .then(data => {
// data.forEach(item => {
// new mapboxgl.Marker()
// .setLngLat([item.geometry.location.lng, item.geometry.location.lat])
// .addTo(map);
// });
// })
// .catch(error => console.error('Error:', error));
// });
4 changes: 2 additions & 2 deletions heatmap.html → index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
<link href='https://api.mapbox.com/mapbox-gl-js/v2.6.1/mapbox-gl.css' rel='stylesheet' />
</head>
<body>
<div id='map' style='width: 100%; height: 100vh;'></div>
<div id='map' style='width: 99vw; height: 98vh;'></div>
<script src='https://api.mapbox.com/mapbox-gl-js/v2.6.1/mapbox-gl.js'></script>
<script src='heatmap.js'></script>
<script src='code/heatmap.js'></script>
</body>
</html>
Loading

0 comments on commit 40383bd

Please sign in to comment.