I have a geojson file and I get it with ajax. but I want to prevent the editing of the geometries I load during startup. Only the ones that are added with leaflet.pm should be editable. How can i do it ?
I'm using geojson coordinate json. these drawings are added to the map when the page loads.
{pmIgnored: true} after trying to delete delete mode when I click on one of the static drawings I added from geojson deletes all of them. How can I prevent it?
var geojsonData;
// addded geojson ajax
$.getJSON("geo.json", {
async: false,
}, function (data) {
geojsonData = L.geoJson(data, {
pmIgnore: true, // ignore static shaped edited
style: {
weight: 20
},
}).addTo(map);
});
what I want to do is not to delete static coordinates in any way when deletion mode is turned on