springboot——修改html实时生效,不用重启tomca(idea版)

第一步:

在全局配置文件(application.properties)中禁用thymeleaf模板引擎的缓存,缓存是默认开启的

spring.thymeleaf.cache=false

第二步:

在idea中按 ctrl+f9 重新编译一下html文件。

 

建议:开发环境中可以禁用thymeleaf模板引擎的缓存,提高开发效率,但是生产环境中建议开启。

posted on 2020-10-26 16:33  adolfmc  阅读(477)  评论(0编辑  收藏  举报