yml报错:deprecated configuration property spring.thymeleaf.content-type

今天在yml文件中配置thymeleaf时候报错deprecated configuration property spring.thymeleaf.content-type

thymeleaf:
       cache: false
       prefix: classpath:/templates/
       suffix: .html
       encoding: UTF-8
       content-type: text/html
       mode: HTML5

意思是这个属性已经过时不被使用

改为

thymeleaf:
       cache: false
       prefix: classpath:/templates/
       suffix: .html
       encoding: UTF-8
       servlet:
          content-type: text/html
       mode: HTML5

 

你可能感兴趣的:(SpringBoot)