altTemplate Function

Template to be used for rendering the alternate items in the ListView.

The outermost HTML element in the template must be enclosed in another container such as a div or span element.

Example of alternate item template

 <script type="text/kendo-x-tmpl" id="template">
        Item template for #:name#

 <script type="text/kendo-x-tmpl" id="altTemplate">
        Alternate item template for #:name#

 <div id ="listView"></div>
    dataSource: {
        data: [
            { name: "Jane Doe" },
            { name: "John Doe" }
    template: kendo.template($("#template").html()),
    altTemplate: kendo.template($("#altTemplate").html())
In this article