Skip to content

Commit

Permalink
#86 fix : 멀티 모듈 적용시 hilt에러 수정
Browse files Browse the repository at this point in the history
각 모듈에 implmentation을 하는 것은 이상해 보이니 다시 수정 요망
  • Loading branch information
BENDENG1 committed Jan 29, 2024
1 parent 1daf55d commit c65e8a9
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
9 changes: 5 additions & 4 deletions Aos/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ plugins {
id("org.jetbrains.kotlin.android")
id("kotlin-kapt")
id("com.google.gms.google-services")
id("dagger.hilt.android.plugin")
}

android {
Expand Down Expand Up @@ -71,10 +72,10 @@ dependencies {
// androidTestImplementation("androidx.test.ext:junit:1.1.5")
// androidTestImplementation("androidx.test.espresso:espresso-core:3.5.1")

// // hilt
// val hiltVersion = "2.48"
// implementation("com.google.dagger:hilt-android:${hiltVersion}")
// kapt("com.google.dagger:hilt-android-compiler:${hiltVersion}")
// hilt
val hiltVersion = "2.48"
implementation("com.google.dagger:hilt-android:${hiltVersion}")
kapt("com.google.dagger:hilt-android-compiler:${hiltVersion}")
//
// // retrofit
// val retrofitVersion = "2.9.0"
Expand Down
5 changes: 2 additions & 3 deletions Aos/app/src/main/java/com/avengers/nibobnebob/app/App.kt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import androidx.datastore.core.DataStore
import androidx.datastore.preferences.core.Preferences
import androidx.datastore.preferences.preferencesDataStore
import com.avengers.nibobnebob.BuildConfig
import com.avengers.nibobnebob.presentation.util.Constants.APP_NAME
import com.navercorp.nid.NaverIdLoginSDK
import dagger.hilt.android.HiltAndroidApp

Expand All @@ -24,7 +23,7 @@ class App : Application(){

companion object{
lateinit var instance : App
val Context.dataStore: DataStore<Preferences> by preferencesDataStore(name = APP_NAME)
val Context.dataStore: DataStore<Preferences> by preferencesDataStore(name = "NibobNebob")
fun getContext(): Context = instance.applicationContext
}

Expand All @@ -33,7 +32,7 @@ class App : Application(){
applicationContext,
BuildConfig.NAVER_LOGIN_CLIENT_ID,
BuildConfig.NAVER_LOGIN_CLIENT_SECRET,
APP_NAME)
"NibobNebob")
NaverIdLoginSDK.showDevelopersLog(true)
}
}
6 changes: 6 additions & 0 deletions Aos/presentation/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ plugins {
id("org.jetbrains.kotlin.android")
id("kotlin-kapt")
id("androidx.navigation.safeargs.kotlin")
id("dagger.hilt.android.plugin")
}

android {
Expand Down Expand Up @@ -65,4 +66,9 @@ dependencies {
// naver Login
api ("com.navercorp.nid:oauth:5.8.0")

// hilt
val hiltVersion = "2.48"
implementation("com.google.dagger:hilt-android:${hiltVersion}")
kapt("com.google.dagger:hilt-android-compiler:${hiltVersion}")

}

0 comments on commit c65e8a9

Please sign in to comment.