使用idea搭建springboot项目
点击new project之后如图所示
选择java 8
新建controller目录新建控制器类
写上接口的路径
在pom.xml文件上加入依赖
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
在resources目录下新建template和a目录以及html页面
b.html
<!doctype html>
<html >
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Document</title>
</head>
<body>
欢迎大家来到java的世界大门
</body>
</html>