스프링부트에서 정적 파일(html, js, css) 자동 반영(LIVELOAD) 설정 하기(intellij, gradle 기준)
build.gradle 의존성 추가
implementation 'org.springframework.boot:spring-boot-devtools'
application.properties 추가
spring.devtools.livereload.enabled=true
intellij settings 변경
- compiler 탭에서
Build project automatically
체크 - advanced setting 탭에서
Allow auto-make to start even if developed application is currently running
체크
혹시라도 안될 경우 브라우저 캐시제거 및 캐시제거 새로고침(ctrl+F5) 할 것!
댓글