JSFiddle - React, Tailwind, and code Playground

by calder12

HTML

<div id="test" class="test1"></div><div id="test"class="test1"></div> 
<button id="click">Click Me</button><br />
<button id="reset">Reset</button><br />
<button id="click-next">Click Me</button>

CSS

#test { 
background-color: green; 
width: 100px; 
height: 100px; 
margin-top: 5px; 
} 
#test { 
background-color: red; 
width: 100px; 
height: 100px; 
margin-top: 5px; 
}

JavaScript

$("#click").on("click",function(){
    $("#test").css("background-color","green");
});
$("#reset").on("click",function(){
    $(".test1").css("background-color","red");
});
$("#click-next").on("click",function(){
    $(".test1").css("background-color","green");
});