I have an HTML-structure:
<div class="parent">
<div class="item">1</div>
<div class="item">2</div>
<div class="item">3</div>
<div class="item item--right">4</div>
<div class="item item--right">5</div>
</div>
And styles:
.parent {
display: flex;
flex-wrap: no-wrap;
align-content: flex-start;
}
.item {
width: 50px;
}
I want items 1, 2 and 3 to be on the left, and items 4 and 5 on the right.
I was trying to solve this problem using align-self: right
:
.item--right {
align-self: right;
}
But it didn't help.
Here's my fiddle. What am I doing wrong?