# Rows

The rows property defines the data source for the rows content - see Loading data for the details.

const rows = [
    { field1: 'value1', field2: 'value2', ...}
];    

# Row object

You can access row model object via row event:

function onRow(row){

    const { country, state, zip, address } = row.data;  // ref to data record

    row.cells.custom1 = 'abc'; // calculated values
    row.style = { background: '#eee' }; // dynamic styles
    row.template = 'my-row-tpl'; // custom row template
}

# Global defaults

It is possible to set the default params for all rows with row option:

import { row } from "@activewidgets/options";

const options = [
    row({ style: { color: '#777' }})
];