타임리프에서 배열의 index값 출력하기

jyp·2023년 3월 30일
0

맥북으로 혼공하기

목록 보기
24/32

index = 0부터 시작, count = 1부터 시작

<tr th:each="svo,rank:${list}">	
	<td th:text="${svo.name}"></td>
	<td th:text="${svo.kor}"></td>
	<td th:text="${svo.eng}"></td>
	<td th:text="${svo.mat}"></td>
	<td th:text="${svo.avg}"></td>
	<td th:text="${rank.count}"></td>
</tr>
profile
국비 코딩

0개의 댓글