From 2091a0bf067cecbf16f5e6db569c30d916a8570d Mon Sep 17 00:00:00 2001 From: chanu Date: Wed, 3 Jan 2024 06:47:37 +0900 Subject: [PATCH] =?UTF-8?q?[chore]=20:=20di=20hilt=20=EB=9D=BC=EC=9D=B4?= =?UTF-8?q?=EB=B8=8C=EB=9F=AC=EC=A7=80=20=EC=B6=94=EA=B0=80,=20=EC=9E=90?= =?UTF-8?q?=EB=B0=94=20=EB=B2=84=EC=A0=84=2017=EB=A1=9C=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/build.gradle | 15 +++++++++++---- build.gradle | 3 ++- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index d9f76bf..f8a2c40 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -3,6 +3,8 @@ plugins { id 'org.jetbrains.kotlin.android' id 'org.jetbrains.kotlin.plugin.serialization' version '1.8.20' id 'kotlin-parcelize' + id 'kotlin-kapt' + id 'com.google.dagger.hilt.android' } Properties properties = new Properties() @@ -31,21 +33,26 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_11 - targetCompatibility JavaVersion.VERSION_11 + sourceCompatibility JavaVersion.VERSION_17 + targetCompatibility JavaVersion.VERSION_17 } kotlinOptions { - jvmTarget = '11' + jvmTarget = '17' } buildFeatures { buildConfig true viewBinding true dataBinding true } - + // Allow references to generated code + kapt { + correctErrorTypes true + } } dependencies { + implementation "com.google.dagger:hilt-android:2.44" + kapt "com.google.dagger:hilt-compiler:2.44" // viewmodel 의존성 추가 implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.2" diff --git a/build.gradle b/build.gradle index fd3d478..205b53a 100644 --- a/build.gradle +++ b/build.gradle @@ -3,4 +3,5 @@ plugins { id 'com.android.application' version '8.0.2' apply false id 'com.android.library' version '8.0.2' apply false id 'org.jetbrains.kotlin.android' version '1.8.20' apply false -} \ No newline at end of file + id 'com.google.dagger.hilt.android' version '2.44' apply false +}