Skip to main content

map()

iterates through all items of the component

map(callback: DataCallback<T>): T[];

Parameters:

callback: function - a function that will be called for each item of a component

Returns:

A new array of items where each item is the result of the callback function.

Example

//getting ids of all items of the componentcomponent.data.map(function(item){    return item;});

Related sample: Data. Map