今天写代码,发现SpringBoot项目运行之后,就是找不到index.html,编写了Config配置类也不行,最后在网上去查找,发现都是以前的版本的方法。
目前使用的是:
# 参数是String[],可以指定多个
spring:
web:
resources:
static-locations: classpath:/templates/,classpath:/static/
今天写代码,发现SpringBoot项目运行之后,就是找不到index.html,编写了Config配置类也不行,最后在网上去查找,发现都是以前的版本的方法。
目前使用的是:
# 参数是String[],可以指定多个
spring:
web:
resources:
static-locations: classpath:/templates/,classpath:/static/