电影网站增删改查-3 spring boots/MVC/neo4j/thymeleaf 源码分析 thymeleaf 配置

前提

1. 添加依赖 

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

2.

spring-boot很多配置都有默认配置,比如默认页面映射路径为 
classpath:/templates/*.html 
同样静态文件路径为 
classpath:/static/


但是我在WEB-UI 下面找不到如下配置:

#thymeleaf start
spring.thymeleaf.mode=HTML5
spring.thymeleaf.encoding=UTF-8
spring.thymeleaf.content-type=text/html
#开发时关闭缓存,不然没法看到实时页面
spring.thymeleaf.cache=false
#thymeleaf end


application.properties 这个文件也找不到 在哪里!!!


有种说法是在resources 里面增加templates 目录,存放html 文件?

《电影网站增删改查-3 spring boots/MVC/neo4j/thymeleaf 源码分析 thymeleaf 配置》


further ref: http://blog.csdn.net/u012706811/article/details/52185345

    原文作者:Spring Boot
    原文地址: https://blog.csdn.net/sylmoon/article/details/78100132
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞