spring boot 极简案例
安装idea
File -> New Project
选择依赖
创建controller文件
输入controller类名
输入代码
运行项目
访问
package com.example.demo; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @RestController @RequestMapping("/hello") public class HelloController { @RequestMapping("/boot") public String helloBoot() { return "Hello Spring Boot hha"; } }