JSFiddle - React, Tailwind, and code Playground

HTML

<div id="home">
<div class="something">
    <div class="section_header"><h1 class="left" data-target="newest">Newest</h1></div>
    <div class="section_header"><h1 class="left" data-target="best">Best</h1></div>
</div>

<div id="newest">
        helllo home
    </div>


    <div id="best">
        helllo best
    </div>

</div>

CSS

.section_header {
    cursor: pointer;
}

JavaScript

$('.section_header h1').on('click', function(){
    $('#home > div:not(.section_header)').hide();
    $('#' + $(this).data('target')).show();
}).first().click();