layers.tooltip.template String|Template
The template which renders the tooltip content.
The fields which can be used in the template are:
- location - the marker location (
kendo.dataviz.map.Location
instance) - marker - the marker instance
Setting a template disables the content option.
Example - set tooltip template
<div id="map"></div>
<script>
$("#map").kendoMap({
layers: [{
type: "marker",
tooltip: {
template: "Lon:#= location.lng #, Lat:#= location.lat #"
},
dataSource: {
data: [{
latlng: [0, 0]
}]
},
locationField: "latlng"
}]
});
</script>
Example - use formatted dataItem value in the tooltip template
<div id="map"></div>
<script>
$("#map").kendoMap({
layers: [{
type: "marker",
tooltip: {
template: "#= kendo.toString(marker.dataItem.value, 'C') #"
},
dataSource: {
data: [{
latlng: [0, 0],
value: 1000
}]
},
locationField: "latlng"
}]
});
</script>