![](https://img-blog.csdnimg.cn/20190927151132530.png?x-oss-process=image/resize,m_fixed,h_224,w_224)
thymeleaf
thymeleaf
寒小韩_
哈哈!菜鸟小猿一枚~
展开
-
thymeleaf常用变量表达式
变量表达式变量表达式有丰富的内置方法,使其更强大,更方便。变量表达式功能(1)可以获取对象的属性和方法(2)可以使用ctx,vars,locale,request,response,session,servletContext内置对象(3)可以使用dates,numbers,strings,objects,arrays,lists,sets,maps等内置方法(重点介绍)常用的内...原创 2020-05-06 13:29:29 · 829 阅读 · 0 评论 -
Thymeleaf在SpringBoot中的使用
spring.thymeleaf.cache = true 启用模板缓存(开发时建议关闭)spring.thymeleaf.check-template = true 检查模板是否存在,然后再呈现spring.thymeleaf.check-template-location = true 检查模板位置是否存在spring.thymeleaf.content-type = text/html...原创 2020-05-01 15:10:03 · 149 阅读 · 0 评论 -
Thymeleaf快速入门
Thymeleaf 入门1. 简单表达式1.1 外部化文本 #{---}外部化文本是从模板文件中提取模板代码的片段,以便它们可以保存在单独的文件(通常为 .properties 文件)中,并且可以轻松地替换为使用其他语言编写的等效文本(称为国际化或简单的i18n) 。文本的外部化片段通常称为“消息(messages)”。<p th:text="#{home.welcome}">...原创 2020-05-01 15:08:15 · 122 阅读 · 0 评论