JSFiddle - React, Tailwind, and code Playground
HTML
<ul>
<li>1a</li><li>2a</li><li>3a</li><li>4a</li><li>5a</li><li>6a</li>
</ul>
CSS
ul {
list-style: none;
margin: 0;
padding: 0;
text-align: right;
}
li {
/* float: none; */
}
li:nth-last-child(1), li:nth-last-child(2), li:nth-last-child(3) {
/* float: none; */
display: inline-block;
}