JSFiddle - React, Tailwind, and code Playground
HTML
<div id="red"></div>
<div id="gray"></div>
CSS
#red {
width: 100px;
height: 100px;
background: red;
}
#gray {
width: 100px;
height: 100px;
background: gray;
margin-top: 10px;
}
JavaScript
var someBlock = document.getElementById('red'),
hiddenBlock = document.getElementById('gray');
someBlock.addEventListener('click', function() {
hiddenBlock.style.display = "none";
})