Vì Thymeleaf chỉ render được html ở server nên chúng ta sẽ sử dụng javascript ở client để chuyển timestamp sang string: Bước 1: Ở phía server bạn sẽ chuyển hết DateTime về dạng timestamp (long) Bước 2: Code ...
Home/thymeleaf
Stack Ask Latest Questions
Code hiển thị message dạng chữ hoa trong thymeleaf: <li class="nav-header" th:with="componentsTitle=#{components.title}" th:text="${#strings.toUpperCase(componentsTitle)}"></li> Tham khảo thêm: https://www.thymeleaf.org/doc/tutorials/3.0/usingthymeleaf.html#strings
Thymeleaf hiển thị text mà không cần sử dụng thẻ html, có thể sử dụng cách này: <p th:inline="text"> [[${menu.name}]] <i class="fas fa-angle-left right"></i> </p>