JSFiddle - React, Tailwind, and code Playground
HTML
<div class="stubborn"></div>
<button onclick="show()">show</button>
<button onclick="hide()">hide</button>
CSS
body { background-color: #000; }
div.stubborn { display: none !important; background-color: red; width: 100px; height: 100px; }
div.stubborn.fade-ready { display: block !important; opacity: 0; }
JavaScript
function show() {
$('.stubborn').addClass('fade-ready').animate({opacity: 1});
}
function hide() {
$('.stubborn').fadeOut(function() {
$(this).removeClass('fade-ready');
});
}