First of all, the official recommendation of the use of template technology, such as Freemark, Thymeleaf, of course, can also use JSP, where the simple configuration of the springboot in the JSP support
1. Add support for JSP
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId> tomcat-embed-jasper</artifactid>
<version>8.5.6</version>
<!-- <scope> provided</scope>-->
</dependency>
<!--support for Jstl libs-->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<version >1.2</version>
</dependency>
2, add the view layer configuration in the configuration file
#---------------------Configure view Layer---------------------
# page Default prefix directory
spring.mvc.view.prefix=/web-inf/jsp/
# response page default suffix
spring.mvc.view.suffix=.jsp
#页面向后台传入日期格式化
spring.mvc.date-format= "Yyyy-mm-dd HH: Mm:ss "
To do this