JSFiddle - React, Tailwind, and code Playground

by tiagocarvalho

HTML

<div id="divWithButtonInside">
<input type='button' onclick='functionToRemove();' value='Form Checker' />
</div>
<input type='button' onclick='removeOnClick()' value='click to remove event' />

JavaScript

function removeOnClick() {
      var cat = document.getElementById("divWithButtonInside");
      var sub = cat.getElementsByType("button");
      sub[0].style.display='inline'; 
      alert();
}

function functionToRemove()
{
    alert("Don't work");
}