add

Adds a new item. If an optional beforeElement is provided as second parameter, the new item is added before it.

Parameters

item Object (required)

The item definition that will be added.

beforeElement HTMLElement|jQuery (optional)

Add item before an already existing item.

Example

<div id="chiplist"></div>

<script>
    var chiplist = $("#chiplist").kendoChipList({
        items: [
            { label: "Home", icon: "home" }
        ]
    }).data("kendoChipList");

    chiplist.add({ label: "Contact", icon: "envelope", attributes: { id: "email" } });
    chiplist.add({ label: "Info", icon: "info-circle" }, $("#email"));
</script>
In this article