Flow

flow is vertical with flex-wrap: wrap. It’s named flow because it allows elements within to flow to subsequent lines when there’s insufficient space.


Let items flow to the next line

flow is horizontal with flex-wrap so items can flow to subsequent lines.

index.html
<div class="flow"> ... </div>
Lorem
ipsum
dolor
sit
amet
consectetur
adipisicing
elit

Adjust the space between items easily

With flow, you can adjust space between items with gap. It’s more intuitive than margin because there’s no need to deal with “margin collapse”.

index.html
<div class="flow gap-8"> ... </div>
Lorem
ipsum
dolor
sit
amet
consectetur
adipisicing
elit

Easily justify items to the left, center, or right.

You can use justify-content to shift all items to the left, center, or right.

Start
One
Two
Three
Center
One
Two
Three
End
One
Two
Three