JSFiddle - React, Tailwind, and code Playground
HTML
<table>
<thead>
<tr>
<th>a</th>
<th>b</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>2</td>
</tr>
</tbody>
</table>
CSS
table, th, td {
border: 1px solid black;
}
JavaScript
$(function() {
$( "th:nth-child(2)" ).append( "<span><input type='checkbox'></input> Check all</span>" );
});