include

Grows the extent, if required, to contain the specified location.

Example

<div id="map"></div>
<script>
var extent = new kendo.dataviz.map.Extent(
    new kendo.dataviz.map.Location(42.3601, -71.0589), // Boston
    new kendo.dataviz.map.Location(40.7128, -74.0060)  // New York
);

console.log("Original extent center:", extent.center());

// Include a location outside the current extent
var washingtonDC = new kendo.dataviz.map.Location(38.9072, -77.0369);
extent.include(washingtonDC);

console.log("Extended extent center:", extent.center());

$("#map").kendoMap({
    center: extent.center(),
    zoom: 6
});
</script>

Parameters

location kendo.dataviz.map.Location

The location to include in the extent.

In this article
include
Not finding the help you need?
Contact Support