Last active
July 26, 2020 01:56
-
-
Save prasannajeet/67505cb87ee7e6bef745e47eadde6b6c to your computer and use it in GitHub Desktop.
Adding Hilt to Android
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apply plugin: 'dagger.hilt.android.plugin' | |
// Since these are alpha dependencies and subject to change they will remain outside of the | |
// dependencies.gradle script till they reach 1.0.0 | |
implementation "com.google.dagger:hilt-android:2.28-alpha" | |
kapt "com.google.dagger:hilt-android-compiler:2.28-alpha" | |
implementation 'androidx.hilt:hilt-lifecycle-viewmodel:1.0.0-alpha02' | |
kapt 'androidx.hilt:hilt-compiler:1.0.0-alpha02' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dependencies { | |
classpath "com.android.tools.build:gradle:4.0.0" | |
classpath "com.android.tools.build:gradle:4.0.1" | |
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" | |
def nav_version = "2.3.0" | |
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:$nav_version" | |
classpath 'com.google.dagger:hilt-android-gradle-plugin:2.28-alpha' | |
// NOTE: Do not place your application dependencies here; they belong | |
// in the individual module build.gradle files | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment