JSFiddle - React, Tailwind, and code Playground
by JSWorld
HTML
<table>
<thead>
<tr>
<td>ONE</td>
<td>TWO</td>
</tr>
</thead>
<tbody id="table_tbody">
</tbody>
</table
JavaScript
$(document).ready(function() {
var element = $("<tr>").append($("<td>").text("bla1"))
.append($("<td>").text("bla2"));
for (var ind = 0; ind < 10; ++ind) {
var elem = element.clone();
elem.children().next().first().attr("class", "table_td");
$('#table_tbody').append(elem);
}
$(document).on('click', '.table_td', function(){
playerFunc();
});
});
var playerFunc = function() {
alert("hren");
}