thymeleaf if set is empty code example Example: thymeleaf if string empty <div th:if= "${searchResults.results != ''}">