JSFiddle - React, Tailwind, and code Playground
by mvasko
HTML
<div id="1"></div>
<div id="2"></div>
CSS
#1{
width:50px;
height:50px;
background-color:green;
}
#2{
width:50px;
height:50px;
background-color:blue;
}
JavaScript
$(document).ready(function(){
$("#1").mouseenter(function(){
$("#2").animate({left:'250px'});
});
});
$(document).ready(function(){
$("#1").mouseleave(function(){
$("#1").animate({left:'10px'});
});
});