1. 进入sPRing boot 官网 点击打开链接
2. 将下载好的demo 导入maven工程
3. 等待maven 下载相关jar包 下载完成后 在pom.xml 中引入 web 模块
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId></dependency>4. 在 com.example 包名下 新建包并创建 测试 control (PS:不要随意更改包名 ,application 类直接放在主包下)
5. run as DemoApplication类 启动成功后 访问http:localhost:8080/hello 一个基本的 基于web 的 spring boot 项目就搞定了
新闻热点
疑难解答