JSFiddle - React, Tailwind, and code Playground
HTML
<div class="menuButton">Hello World</div>
CSS
.menuButton {
position: absolute;
top: 100px;
left: 100px;
transition: transform 1000ms, opacity 500ms 1000ms;
}
.menuButton.hideMe {
transform: rotate(90deg);
opacity: 0;
}
JavaScript
$('.menuButton').click(function() {
$(this).addClass('hideMe');
});//end click