SpringBoot整合thymeleaf3.0版本时出现“springboot cannot resolve MVC view”问题

出现该问题且报404的解决方法:
在pom.xml加上“-spring5”,如下:

<properties>
    <java.version>1.8</java.version>
    <thymeleaf-spring5.version>3.0.2.RELEASE</thymeleaf-spring5.version>
    <thymeleaf-layout-dialect.version>2.1.1</thymeleaf-layout-dialect.version>
</properties>

版权声明:本文为weixin_40176862原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。