JSFiddle - React, Tailwind, and code Playground

HTML

<html>
    <body>
        <span id="left">This will slide left</span>
        <span id="right">This will follow but remain visible</span>
        <br/>
        <input type="button" value="Go!" id="button"/>
    </body>
</html>

CSS

#left {
    background: #ccc;
}
#right {
    background: #ccc;
}

JavaScript

$('#button').click(function() {
    $('#left').hide("slide");
});