1) 在application.properties中设置thymeleaf 模板引擎的缓存为false,默认为true开启的 spring thymelefa.cache=false 2) 在编辑入口类On uodate action On feame deactivtion 全部选择 "update resources"