$(document).ready(function () { var map = L.map('map').setView([51.505, -0.09], 13); L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { attribution: '© OpenStreetMap contributors' }).addTo(map);
var geojsonMarkerOptions = { radius: 25, fillColor: "#24D238", color: "#A9F6B2", weight: 2, opacity: 1, fillOpacity: 1
};
const spotsLayer = L.layerGroup(); $.getJSON('---PATH TO YOUR LOCAL COPY OG SPOTS.JSON ---', function (data) { for (var k in data) {
var spotMarker = L.marker([data[k].Lat, data[k].Lon], geojsonMarkerOptions); spotMarker.pointID = data[k].ID;
spotMarker.addTo(spotsLayer); } }); spotsLayer.addTo(map); });