JSFiddle - React, Tailwind, and code Playground

by zono

HTML

<div id="buttonsHolder">
    <input type="button" value="button"/>
</div>

JavaScript

$(document).on("click", "input[type='button']", function() {
    alert("clicked");
});

// add two buttons 
$("<input/>", {
    type: "button",
    value: "button"
}).appendTo("#buttonsHolder");

$("<input/>", {
   type: "button",
   value: "button"    
}).appendTo("#buttonsHolder");