1.创建maven工程
idea +maven 搭建spring boot 项目点击next:

idea +maven 搭建spring boot 项目点击finish maven项目创建成功!
2.pom.xml文件配置
打开pom.xml并添加一下内容:

org.springframework.boot
spring-boot-starter-parent
2.3.0.RELEASE

3.添加 Classpath 依赖


org.springframework.boot
spring-boot-starter-web


idea +maven 搭建spring boot 项目
4.编写代码
创建启动类Application—名字自定义
idea +maven 搭建spring boot 项目
右键运行(8080为默认端口):
idea +maven 搭建spring boot 项目
测试:http://127.0.0.1:8080/home
idea +maven 搭建spring boot 项目
测试成功!!!

相关文章:

  • 2021-07-31
  • 2021-08-02
  • 2021-12-06
  • 2022-12-23
  • 2021-04-03
  • 2021-11-15
  • 2021-10-15
  • 2022-12-23
猜你喜欢
  • 2021-11-26
  • 2021-05-30
  • 2021-07-21
  • 2021-08-06
  • 2022-03-03
  • 2021-11-03
  • 2021-10-10
相关资源
相似解决方案