springboot+thymeleaf找不到模板文件问题:template might not exist or might not be accessible by any of the conf

时间:2024-03-31 15:16:22

关于SpringBoot+thymeleaf找不到模板问题:template might not exist…

今天在整合thymeleaf时出现一个怎么百度也没有解决的问题,最后按照错误的源码进行调试。。。。(spring-boot-starter-thymeleaf版本为:2.2.4)

  • 根据对应的错误信息找到解析方法springboot+thymeleaf找不到模板文件问题:template might not exist or might not be accessible by any of the conf
  • springboot+thymeleaf找不到模板文件问题:template might not exist or might not be accessible by any of the conf
  • springboot+thymeleaf找不到模板文件问题:template might not exist or might not be accessible by any of the conf
  • springboot+thymeleaf找不到模板文件问题:template might not exist or might not be accessible by any of the conf
  • 最后发现,执行出来的资源名称最后多了一个空格,难怪找到模板。