1、启动项目,访问templates文件夹下的login.html页面,报如下错误:
控制台报错信息:org.thymeleaf.exceptions.TemplateInputException: Error resolving
template "login", template might not exist or might not be accessible by any of
the configured Template Resolvers。。。
2、问题解决:报错之后在项目中一顿排查,发现是我的pom.xml中的配置导致的,删除如下配置即可:
<resources>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>**.*</include>
</includes>
</resource>
</resources>
热门工具 换一换