JSFiddle - React, Tailwind, and code Playground

HTML

<div id="hideme">click to hide</div>

CSS

#hideme{
 width:50px;
height:50px;
cursor:pointer;
 border:1px solid gray;      
}

JavaScript

$("#hideme").click(function(){
   $(this).slideToggle();
});