JSFiddle - React, Tailwind, and code Playground
HTML
<a href="#" id="testing">Testing</a>
<div id="testing1"></div>
JavaScript
$(document).ready(function() {
$('#testing').click(function () {
$('#testing1').html('<a href="#" id="testing22">click me again which should prompt an alert</a>');
});
$('#testing22').click(function() {
alert("i rock");
});
});