JSFiddle - React, Tailwind, and code Playground

by Thiago Diniz

HTML

<a href="#" id="menu-usuario">TROCA
</a>

<div id="texto">
    TEXTO
</div>

CSS

.inative{
    color:#F00;
}

.active{
    color:black;
}

JavaScript

$("#menu-usuario").click(function(){
    $("#texto").toggleClass('active, inative');
});