Spring boot 整合JSP开发步骤


1. 新建Springboot项目,war

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
<version>2.1.3.RELEASE</version>
<scope>provided</scope>
</dependency>

  

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
<version>2.1.3.RELEASE</version>
<scope>provided</scope>
</dependency>

provided的意思是将项目打包时,不需要将内置tomcat一起打包。


2. 建立基本的web项目所需要的目录结构
webapps/WEB-INF(需要)
webapps/WEB-INF/web.xml (不需要)

原文地址:https://www.cnblogs.com/qianjinyan/p/10418363.html