JSFiddle - React, Tailwind, and code Playground
HTML
<div id="content">
<div class="post">
<h3>Test 1</h3>
<div>
lorem ipsum dolor sit amet.
</div>
</div>
<div class="post">
<h3>Test 2</h3>
<div>
aap noot mies.
</div>
</div>
<div class="post">
<h3>Test 3</h3>
<div>
fietspomp
</div>
</div>
<div class="post">
<h3>Test 4</h3>
<div>
lorem ipsum dolor sit amet.
</div>
</div>
</div>
CSS
#content {
height: 200px;
width: 200px;
overflow: auto;
position: relative;
}
.post {
overflow: hidden;
position: absolute;
z-index: 1;
top: 50px;
left: 0;
height: 200px;
background: #fff;
}