I have a layout where sometimes the 'left' item is missing. In such cases, I still want the 'right' item to be right-aligned.
I thought I could do this with justify-self
but that doesn't appear to be the case.
Is there a flexbox property for right-aligning one's self?
.row {
border: 1px solid black;
display: flex;
justify-content: space-between;
align-items: center;
}
.left,
.right {
display: inline-block;
background-color: yellow;
}
.right {
justify-self: flex-end;
}
<div class="row">
<!--<div class="left">left</div>-->
<div class="right">right</div>
</div>