Skip to main content

template

specifies a template for List items

template?: (obj: IDataItem) => string;

Example

var list = new dhx.List("list", {    template: function(item) {        return "<strong>!!!</strong>" + item.value;    }});

Related sample: List. Add Template To List Item

The template function takes one parameter:

item(object) an object of a data item