JSFiddle - React, Tailwind, and code Playground
HTML
<div id="box"></div>
<button>CLICK</button>
CSS
#box {
width: 150px;
height: 0;
background: red;
transform: scale(0);
transition: transform .5s;
}
#box.active {
transform: scale(1);
display: block;
height: 150px;
}
JavaScript
$("button").on("click", function () {
$("#box").addClass("active");
});