dataSourceObject|Array|kendo.data.HierarchicalDataSource
The data source of the treeMap which is used to display the tiles and titles. Can be a JavaScript object which represents a valid data source configuration, a JavaScript array or an existing kendo.data.HierarchicalDataSource instance.
If the HierarchicalDataSource
option is set to a JavaScript object or array the widget will initialize a new kendo.data.HierarchicalDataSource instance using that value as data source configuration.
If the HierarchicalDataSource
option is an existing kendo.data.HierarchicalDataSource instance the widget will use that instance and will not initialize a new one.
Example
<div id="treemap"></div>
<script>
$("#treemap").kendoTreeMap({
dataSource: [
{
name: "Technology",
value: 30,
items: [
{ name: "Mobile", value: 15 },
{ name: "Desktop", value: 15 }
]
},
],
valueField: "value",
textField: "name"
});
</script>
In this article