場景:
Springboot 項目的頁面和靜態文件,在項目啓動後,修改無效。按照下面的配置可以解決問題。
解決方案:
步驟一
點擊 File–>setting–>Build,Execution,Deployment,勾選Build project automatically,點擊apply。
步驟二
- 使用快捷鍵Shift+Ctrl+Alt+/,然後選擇Registry
2.勾選compiler.automake.allow.when.app.running
上圖是2021版前的compiler.automake.allow.when.app.running
而2021版後的IDEA沒有compiler.automake.allow.when.app.running
2021版後的compiler.automake.allow.when.app.running在下圖
重啓IDEA即可
轉自:https://blog.csdn.net/qq_38680405/article/details/124753971