SpringBoot项目使用Thymeleaf
-
pom.xml
引入相关依赖<!--引入thymeleaf依赖--> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-thymeleaf</artifactId> </dependency>
-
静态资源放在
resources/templates/
下 -
HTML文件加入头文件
<!DOCTYPE html> <html lang="en" xmlns:th="http://www.thymeleaf.org"> <head> <meta charset="UTF-8"> <title>title</title> </head> <body> </body> </html>
分类:
算法
标签:
SpringBoot Thymeleaf
版权申明
本文系作者 @卸了磨的驴 原创发布在SpringBoot项目使用Thymeleaf。未经许可,禁止转载。
评论
文章目录
暂无目录
全部评论