JSFiddle - React, Tailwind, and code Playground

HTML

<div id="parent">
    <div id="left"></div>
    <div id="right"></div>
</div>

CSS

#parent{
    background:gray;
    width:49%;
    height:400px;
}
#left{
    float:left;
    background:blue;
    height:30px;

}
#right{
    float:left;
    width:250px;
    background:red;
    height:30px;
}

JavaScript

function rem() {
    var parentw = $('#parent').width();
    var rightw = $('#right').width();
    $('#left').width(parentw - rightw - 1);
}
rem();

$(window).resize(rem)