Created
July 22, 2020 07:15
-
-
Save hasanmohdkhan/2f1f9e97a05b077b2861b77969969ecf to your computer and use it in GitHub Desktop.
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
#project level | |
build.gradle | |
dependencies { | |
//... | |
classpath "com.google.dagger:hilt-android-gradle-plugin:${version_hilt} | |
//... | |
} | |
#Module level | |
build.gradle | |
//Plugin required | |
apply plugin: 'kotlin-kapt' | |
apply plugin: 'dagger.hilt.android.plugin' | |
//Hilt uses Java 8 features. To enable Java 8 in your project, | |
android { | |
... | |
compileOptions { | |
sourceCompatibility JavaVersion.VERSION_1_8 | |
targetCompatibility JavaVersion.VERSION_1_8 | |
} | |
} | |
dependencies { | |
//... | |
implementation "com.google.dagger:hilt-android:$version_hilt" | |
kapt "com.google.dagger:hilt-android-compiler:$version_hilt" | |
//... | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment