JSFiddle - React, Tailwind, and code Playground

by Spokey

HTML

<div id="one"></div>
<div id="two"></div>
<div id="three"></div>

CSS

div {
    position:absolute;
    left:1000px;
    width:200px;
    height:200px;
    background:#eee;
}

JavaScript

var $divs = $('#one, #two, #three')
$divs.draggable({
    drag: function () {
        var t = $(this), l = $(this).offset().left;
        t.text(l);
        if(l < 500){
        t.text('Badaboom');
        }
    }
});