JSFiddle - React, Tailwind, and code Playground

by lechlukasz

HTML

<table>
	<thead><tr><th>i am a table cell inside thead</th></tr></thead>
	<tfoot><tr><td>i am a table cell inside tfoot</td></tr></tfoot>
	<tbody><tr><td>i am a table cell inside tbody</td></tr></tbody>
</table>

JavaScript

var header = $('table>thead>tr');
var body = $('table>tbody>tr');
var footer = $('table>tfoot>tr');

var apppend = function(arr, items) {
    for (var i=0;i<items.lenght;i++)
        arr.push(items[i])
}
var rows = []
append(rows, header)
append(rows, body)
append(rows, footer)

console.log(rows);