<yandex-map
:center="[53.903798,27.560302]"
:zoom="11"
style="width: 100%; height:100%;"
:dragable="true"
:scrollZoom="false"
@created="mapCreated"
@:updateCurrentCoords = "updateCoords"
>
</yandex-map>
updateCoords(localCurrentCoord) {
this.currentCoords = localCurrentCoord;
}
mapCreated: function ($map) {
let pointOnMap = new ymaps.Placemark([55.7204,37.6200], {}, {
draggable: true
});
$map.geoObjects.add(pointOnMap);
this.map = $map;
let coords = [55.7204,37.6200]
pointOnMap.events.add("dragend", function (e) {
let coords = this.geometry.getCoordinates();
let currentCoords = coords[1].toFixed(6) + ',' + coords[0].toFixed(6);
this.$emit('updateCurrentCoords', currentCoords)
}, pointOnMap);
},