thymeleaf-syntax

anonymous·2022년 6월 9일
0

<tbody>
  <tr th:each="article, i: ${list}">
    <td th:text="${article.seq}"></td>
    <td th:text="${article.username}"></td>
    <td sec:authorize="isAuthenticated()">
      <a th:href="${'/board/read/' + article.seq}" th:text="${article.title}"></a>
      <span class="text-blue" th:if="${i.count eq i.size}">[1등]</span>
    </td>
    <td sec:authorize="!isAuthenticated()" th:text="${article.title}"></td>
    <td th:text="${article.writeDate}"></td>
  </tr>
</tbody>

출처

https://yeonyeon.tistory.com/153
https://github.com/yeon-06/inflearnSpring/tree/master/mvc1-3

profile
기술블로거입니다

0개의 댓글