idea使用thymeleaf没有提示解决方法

检查你是否加载了启动包

  <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-thymeleaf </artifactId>
  </dependency>

如果你是直接写的th 使用ALT+ Enter自己加载的 <html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">不报错 启动项目的时候可用但是没有提示
直接把html页面中的那句改为<html lang="en" xmlns:th="http://www.thymeleaf.org">就有提示了

发布了81 篇原创文章 · 获赞 26 · 访问量 4万+

猜你喜欢

转载自blog.csdn.net/weixin_44411569/article/details/103388924