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() {
	 if (hiddenBlock.style.display === "none" ) {
   		hiddenBlock.style.display = "block";
   } else {
   		hiddenBlock.style.display = "none";
   }
})