有没有办法在 Spring Boot 应用程序中发布 Web 内容而无需重新启动整个应用程序?
我使用 thymeleaf 尝试将“spring.template.cache”属性设置为 false,但没有成功
最佳答案
如果您使用mvn spring-boot:run
运行应用程序,设置spring.template.cache
就足够了。
我不确定其他 IDE,但如果从 Intellij IDEA 运行应用程序以刷新 Thymeleaf 模板,您需要 Make Project(Cmd+F9
on Mac) 每次您想看到更改时。
关于web - 在 Spring Boot 应用程序中发布 Web 内容,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21991903/