Tsallaka zuwa abun ciki
Justice Tech School

Order, Gap and align-self

order changes visual order, gap adds space between items and align-self overrides alignment for one item.

Example
<style>
.f { display: flex; gap: 10px; align-items: flex-start; height: 70px; background: #1e293b } .f div { background: #0f766e; padding: 6px } .x { order: -1; align-self: flex-end; background: #f59e0b !important }
</style>
<div class="f"><div>1</div><div>2</div><div class="x">first and low</div></div>

Exercise

Move to the start.

order: ;

Quiz Test

Which property adds space between items?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.