JSFiddle - React, Tailwind, and code Playground

by Todd Levy

HTML

<body class="subdomain">
    <div class="top_bar">test</div>
    <div class="page_measthead">test</div>
</body>

CSS

.top_bar {
    height:100px
}
;

JavaScript

// OFFSET THE SUBDOMAIN PAGE MASTHEAD TO ACCOUNT FOR THE TOP BAR
var offset_masthead = function () {
    $("body.subdomain .page_measthead").css('margin-top', $(".top_bar").height());
};
$(window).on("resize", offset_masthead).resize(); // ATTACH RESIZE HANDLER, INVOKE RESIZE ON LOAD