I have the following piece of code (jsp)
...
<hr>
<div class="actions">
<div class="btn-toolbar">
<c:if test="${condition1}">
<button type="button" class="btn" >
btn1
</button>
</c:if>
<c:if test="${condition2}">
<button type="button" class="btn">
btn2
</button>
</c:if>
<c:if test="${condition3}">
<button type="button" class="btn">
btn3
</button>
</c:if>
</div>
</div>
<hr>
...
Depending on the conditions, div may be empty, and then we get a double hr-tag. Is there an elegant way to display first hr-tag only if div is not empty?