JSFiddle - React, Tailwind, and code Playground

HTML

<body>
<button id="button1">
Create
</button>
<button id="button2">
Change
</button>

JavaScript

$("#button1").click(function(){var elem = $("<p></p>").text("hello").attr("id","created");
                         $("body").append(elem);});
    $("#button2").click(function(){ $("#created").hide();});