From a9ea0c0535a8f80347510d0cbc51d219580c328c Mon Sep 17 00:00:00 2001 From: pavelgalkin Date: Wed, 29 Nov 2017 11:08:20 +0300 Subject: [PATCH] Readme updated --- README.MD | 42 ++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 40 insertions(+), 2 deletions(-) diff --git a/README.MD b/README.MD index 56d537a..c9262f7 100644 --- a/README.MD +++ b/README.MD @@ -52,8 +52,9 @@ You can use the CDN: https://unpkg.com/vue-yandex-maps, `yandexMap` is exposed t Use `` tag to enable the map instance and use attributes to define map options. -You may define placemarks on your map by using `` tag or set an array of objects with placemark options through `` attribute `placemarks`. You also can use both methods together. -The Map instance rerender when changed link on array with markers in `placemarks` property or marker coordinates if marker is a component. +You may define placemarks on your map by using `` tag or set an array of objects with placemark options through `` attribute `placemarks`. You also can use both methods together.
+The Map instance rerender when changed array with markers in `placemarks` property or marker properties if marker is a component.
+Also map watch property `coords` and react without rerender, when it changed. Type of marker in `marker-type` attribute can be: @@ -167,6 +168,7 @@ data() { | circle-radius | Number | Radius of circle in meters. Default value is 1000. | Circle | | cluster-name | String | Attribute for grouping markers in clusters | All | | callbacks | Object | Object, where key is an event name and value is a callback function, e.g. { click: function() {...}, contextmenu: anotherFunction }. [Events list](https://tech.yandex.ru/maps/doc/jsapi/2.1/ref/reference/GeoObject-docpage/#events-summary) | All | +| [balloonTemplate](#balloonTemplate) | String | HTML Template for balloon | All | # Icons @@ -186,6 +188,42 @@ Or you may define it as a placemark with custom icon. In this case you need to s where `markerIcon`: data or computed path to image or data:image/svg+xml;base64, `imageSize`: size of icon in px, `imageOffset`: icon offset in px +# Balloon Template + +You can define your own template for balloon. + +```HTML + + + + +``` + +```JavaScript +computed: { + balloonTemplate() { + return ` +

Hi, everyone!

+

I am here: ${this.coords}

+ + ` + } +} + +``` + +```CSS +.red { + color: red; +} + +``` + # License MIT