1.項目路徑resource下都是存放靜態資源,static可存放圖片,templates則是存放html模板,模板修改以後需重啓服務器才能生效html
2.模板必須放在templates下而且引入,pom中引入spring
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
3.controller服務器