Springboot新手开发坑:1.Springboot+thymeleaf报Error resolving template [index], templatesmight not exist的异常
在使用Springboot开发Maven项目时集成了thymeleaf,集成后报Error resolving template [index], templatesmight not exist的500异常:
仔细检查项目目录无异常,及pom配置无漏配。
控制器代码无异常。
仔细寻找问题,发现在application.properties文件中设置相应的属性有隐藏的空格(prefix后)
导致路径出错,去掉空格后可正常访问所定义的index.html模板。