JSFiddle - React, Tailwind, and code Playground
HTML
<body>
</body>
<a href="#" onclick="fun()" >text9o</a>
JavaScript
$(document).ready(function () {
//Declare outerHTML
(function ($) {
$.fn.outerHTML = function (s) {
return (s)
? this.before(s).remove()
: $('<p>').append(this.eq(0).clone()).html();
}
})(jQuery);
});
function fun()
{
}