728x90
    
    
  반응형
    
    
    
  1. 인텔리제이 설치
2. MariaDB 설치
3. MySQL Workbench 설치
build.gradle 하단에 아래 코드 추가
def frontendDir = "$projectDir/src/main/reactfront"
sourceSets {
    main {
        resources { srcDirs = ["$projectDir/src/main/resources"]
        }
    }
}
processResources { dependsOn "copyReactBuildFiles" }
task installReact(type: Exec) {
    workingDir "$frontendDir"
    inputs.dir "$frontendDir"
    group = BasePlugin.BUILD_GROUP
    if (System.getProperty('os.name').toLowerCase(Locale.ROOT).contains('windows')) {
        commandLine "npm.cmd", "audit", "fix"
        commandLine 'npm.cmd', 'install' }
    else {
        commandLine "npm", "audit", "fix" commandLine 'npm', 'install'
    }
}
task buildReact(type: Exec) {
    dependsOn "installReact"
    workingDir "$frontendDir"
    inputs.dir "$frontendDir"
    group = BasePlugin.BUILD_GROUP
    if (System.getProperty('os.name').toLowerCase(Locale.ROOT).contains('windows')) {
        commandLine "npm.cmd", "run-script", "build"
    } else {
        commandLine "npm", "run-script", "build"
    }
}
task copyReactBuildFiles(type: Copy) {
    dependsOn "buildReact"
    from "$frontendDir/build"
    into "$projectDir/src/main/resources/static"
}'Java Web > 웹 개발 강의' 카테고리의 다른 글
| [Spring Boot] 스프링부트 게시판(JPA, Gradle, Thymeleaf) - 영상 자료 포함 (1) | 2021.07.27 | 
|---|