Idea下@SpringBootApplication保存解决方法

1、在IDEA导入SpringBoot工程时,会出现@SpringBootApplication的异常。如下:

如上所示,导入的工程项目编译时提示错误信息。其原因:IDEA内置了Maven环境,默认采用Maven解决项目依赖问题。工程中的部分依赖不存在。例如Java的程序包:

org.springframework.*;

//同上
org.springframework.stereotype
org.springframework.context
org.springframework.context.support

发布了327 篇原创文章 · 获赞 133 · 访问量 63万+

猜你喜欢

转载自blog.csdn.net/qq_30507287/article/details/103249604