

주의! IntelliJ 에서 프로젝트 열기
압축 풀어서 인텔리제이에서 파일을 열 때 scr/ 폴더가
프로젝트 이름 바로 아래 위치해서 open해야 error가 발생하지 않는다!

위에서 SesacSpringBootApplication 에서 실행버튼을 클릭하면 spring 프로젝트가 실행된다.
localhost:8080에 접속해서 아래와 같이 에러메세지가 나오면 성공!

main/ : 실제 코드를 작성하는 곳test/ : 프로젝트의 소스 코드를 테스트하는 코드 or 리소스 파일build.gradle : 빌드 설정 파일setting.gradle : 빌드 할 프로젝트 정보 설정 파일th:text : 서버에서 전달받은 값을 태그 안에 텍스트로 사용<span th:text="${hello}">message</span>
th:utext : th:text와 유사하며 변수에서 받은 값에 html태그가 있다면 태그 값을 반영해서 표시해준다.
th:value : HTML element 의 value 속성 값을 지정할 때 사용
<button th:value="${hello}" />
th:with : 변수를 사용하고자 할 때 사용<button th:with="temp=${hello}" th:text=${temp} />
th:switch : switch-case문을 이용할 때 사용하며 * 는 default를 의미 <div th:switch="${hello}">
<p th:case="'admin'">hello is admin</p>
<p th:case="'manager'">hello is manager</p>
<p th:case="'*'">hello is other</p>
</div>
th:if : if-else 조건문이 필요할 때 사용되며 else 문은 th:unless 를 사용해야 한다.<p th:if="${hello}=='web'" th:text=${hello}></p>
<p th:unless="${hello}=='web'" th:text="unless입니다."></p>
th:each : 반복문이 필요한 경우 사용<ul>
<li th:each="name:${names}">
<span th:text="${name}">이름</span>
</li>
</ul>