What you need is just a template, which can work with json data to generate html dom structure like bootstrap table.
Use ExtJS XTemplate as an example:
// this is a template
var tableTemplate = new Ext.XTemplate(
'<table class="table {tableClass}">',
'<thead>',
'<tr>',
'<tpl for="columns">',
'<th>{name}</th>',
'</tpl>'
'</tr>',
'</thead>',
'<tbody>',
'<tpl for="row in rows">',
'<tr>',
'<tpl for="column in columns">',
'<td>{row[column]}</td>',
'</tpl>'
'</tr>',
'</tpl>',
'</tbody>',
'</table>'
);
// this is the data load from end-server
var data = {
columns: [{
name: 'a'
}, {
name: 'b'
}, {
name: 'c'
}],
rows: [{
a: 'a1',
b: 'b1',
c: 'c1'
}, {
a: 'a2',
b: 'b2',
c: 'c2'
}, {
a: 'a3',
b: 'b3',
c: 'c3'
}]
};
//generate html with template and data
tableTemplate.overwrite(dom, data);