이 HTML이 있습니다.
<ul>
<li class="completed"><a href="#">I want the icon to stay on the same line as this last <strong>word</strong></li>
</ul>
: after 가상 요소를 사용하여 아이콘을 추가하고 있습니다.
ul li.completed a:after {
background:transparent url(img.png) no-repeat;
content: '';
display:inline-block;
width: 24px;
height: 16px;
}
문제 : 사용 가능한 너비가 너무 작 으면 아이콘이 다음 줄로 바뀝니다. 나는 그것이 추가 된 링크의 마지막 단어와 같은 줄에 머물기를 원할 것이다.

전체 링크에 'nowrap'을 추가하지 않고도이 작업을 수행 할 수 있습니까?