I have a section tag and aside tag enclosed in a main-tag and use float left and right respectively, now I want to make my aside which have float:right to be sticky. Is their a way I can do sticky for the aside-tag? I can actually do it when I'm using a flexbox, but is there a way when using a float?
section {
float: left;
}
aside {
float: right;
position: sticky;
top: 0;
}
<main>
<section>New Section</section>
<aside>New Aside</aside>
</main>