idea配置springboot热部署

springboot项目的页面一调整就看不了效果怎么办?别怕,可以这么做!

idea来配置springboot热部署

1.首先要在项目的pom文件添加以下依赖:
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-devtools</artifactId>
    <optional>true</optional>
</dependency>

2.接下来更改idea的设置

进入到idea的 “File” ,选择 “Settings” ,直接搜索  “Compiler”,把“Build project automatically”选项前面的 √ 打上 。

接下来,根据组合键:“Shift+Ctrl+Alt+/” ,选择 “Registry” ,选中打勾 “compiler.automake.allow.when.app.running”就可以了。

就完成了,改动页面,刷新一下即可。

发布了6 篇原创文章 · 获赞 2 · 访问量 563

猜你喜欢

转载自blog.csdn.net/N4start/article/details/101353057