JSFiddle - React, Tailwind, and code Playground
JavaScript
$(document).ready(function () {
$(document).on('click', '.DeleteMe', function () {
var button = $(this);
var DeleteId = $(this).data("deleteid");
debugger;
$.ajax({
url: "/Merchant/DeleteProduct/" + DeleteId,
type: "Post"
}).done(function () {
$(button).parents("tr").remove();
}).error(function () {
alert("Something Went Wrong.");
})
})
});