问题描述:idea无法解析MVC视图
分析:
1.检查依赖:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-freemarker</artifactId>
</dependency>
2.检查配置文件:
注意template-loader-path的路径配置,看你的ftl文件是否在该文件夹下
freemarker:
cache: false
charset: utf-8
expose-request-attributes: true
expose-session-attributes: true
suffix: .ftl
template-loader-path: classpath:/templates/
resources:
static-locations: classpath:/static/