The default way of initializing dataTables with javascript sourced data is with the data option and it accepts either an array of arrays or an array of objects as far as I know.
var arrayDataSet = [
['Trident', 'Internet Explorer 11', '11'],
['Blink', 'Chrome 35', '35'],
...
];
var objectDataSet = [
{
engine: 'Trident',
browser: 'Internet Explorer 11',
version: '11'
},
{
engine: 'Blink',
browser: 'Chrome 35',
version: '35'
}
...
];
I want to use the createdRow option though and add for example an id and url on each row. I think I want to initialize with data like this instead:
var otherDataSet = [
{
id: 'ie11',
url: 'http://windows.microsoft.com/en-us/internet-explorer/download-ie',
data: {
engine: 'Trident',
browser: 'Internet Explorer 11',
version: '11'
}
},
{
id: 'chr35',
url: 'https://www.google.com/chrome/browser/',
data: {
engine: 'Blink',
browser: 'Chrome 35',
version: '35'
}
}
];
Is it possible?