静态资源
源码
静态资源的处理方式
webjars localhost:8080/webjars/
public,static,/**,resources localhost:8080/
优先级
resources>static(默认)>public
首页相关
源码
将index.html放在静态资源路径下
模板引擎thymeleaf
导包
<dependency>
<groupId>org.thymeleaf</groupId>
<artifactId>thymeleaf-spring5</artifactId>
</dependency>
<dependency>
<groupId>org.thymeleaf.extras</groupId>
<artifactId>thymeleaf-extras-java8time</artifactId>
</dependency>