Skip to main content

data

Optional. Specifies an array of data objects to set into the list

info

Please note that if you specify the id fields in the data collection, their values should be unique. You can also omit the id fields in the data collection. In this case they will be generated automatically.

data: array;

Example

const data = [
{
"title": "The Hobbit and The Lord of the Rings",
"authors": "J.R.R. Tolkien",
"average_rating": 4.59,
"publication_date": "9/25/2012",
"in_store": true,
"isbn13": 9780345538376,
"language_code": "eng",
"num_pages": 1728,
"ratings_count": 101233,
"text_reviews_count": 1550,
"publisher": "Ballantine Books"
},
// more options
]

const list = new dhx.List("list_container", {
css: "dhx_widget--bordered",
template: template,
itemHeight: 72,
data: data
});