|
|
@ -1,10 +1,11 @@
|
|
|
|
import L from 'leaflet';
|
|
|
|
import L from 'leaflet';
|
|
|
|
|
|
|
|
|
|
|
|
var map,marker ;
|
|
|
|
var map, marker;
|
|
|
|
window.addEventListener('load',function () {
|
|
|
|
window.addEventListener('load', function () {
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
|
|
|
|
|
|
|
// delete L.icon.default.prototype._getIconUrl ;
|
|
|
|
// delete L.icon.default.prototype._getIconUrl ;
|
|
|
|
if (!import.meta.env.DEV){
|
|
|
|
if (!import.meta.env.DEV) {
|
|
|
|
L.Icon.Default.mergeOptions({
|
|
|
|
L.Icon.Default.mergeOptions({
|
|
|
|
iconRetinaUrl: "/assets/vendor/leaflet/marker-icon-2x.png",
|
|
|
|
iconRetinaUrl: "/assets/vendor/leaflet/marker-icon-2x.png",
|
|
|
|
iconUrl: "/assets/vendor/leaflet/marker-icon.png",
|
|
|
|
iconUrl: "/assets/vendor/leaflet/marker-icon.png",
|
|
|
@ -30,4 +31,7 @@ window.addEventListener('load',function () {
|
|
|
|
|
|
|
|
|
|
|
|
marker = L.marker({lat: lat, lng: lng}).addTo(map);
|
|
|
|
marker = L.marker({lat: lat, lng: lng}).addTo(map);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
} catch {
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
});
|
|
|
|