解决Error resolving template template might not exist or might not be accessible
- 可能你的controller注解的问题
controller注解和RestController注解的区别 - thymeleaf 在 properties 或 yml 配置文件中相应配置路径问题
关于-
properties
spring.web.resources.static-locations=classpath:/static/, classpath:/templates/
-
yml
spring: thymeleaf: # thymeleaf 页面存放的目录 prefix: classpath:/templates/
-
- return 路径问题
return 路径 - 没有Maven clear