JSFiddle - React, Tailwind, and code Playground

by Hüseyin BABAL

HTML

<div>
	<input type="button" name="button1" id="button1" value="Button 1"/>
	<input type="button" name="button2" id="button2" value="Button 2"/>
</div>

JavaScript

$("input[type='button']").on("click", function() {
	var btnId = $(this).attr("id");
	$(this).remove();
	//deleteButton(btnId);
	
})