JSFiddle - React, Tailwind, and code Playground

HTML

<script type="text/javascript" src="http://code.jquery.com/ui/1.8.23/jquery-ui.min.js"></script>
<link rel="stylesheet" href="http://code.jquery.com/ui/1.8.23/themes/base/jquery-ui.css" type="text/css" media="all" />

<style type="text/css">
    #parent {background:Black; width:100px; height:100px;}
    #child {background:Blue; width:40px; height:100px;}
</style>

<div>
    <div id='parent'>
        <div id='child' />
    </div>
</div>

    <script type="text/javascript">
            
    </script>

</html>

JavaScript

$(function () {
    
    $('#child')
        .resizable({
            containment: '#parent',
            minWidth: 10,
            handles: 'w, e'
        })
        .draggable({
            containment: '#parent'
        });
});