The Hilt Android Gradle plugin is applied but no com.google.dagger:hilt-android-compiler dependency was found

I guess you re missing this dependency kapt “com.google.dagger:hilt-android-compiler:2.28-alpha” *First add the plugin apply plugin: ‘dagger.hilt.android.plugin’ *Secondly add the dependencies // Dagger Core implementation “com.google.dagger:dagger:2.37” kapt “com.google.dagger:dagger-compiler:2.37” // Dagger Android api ‘com.google.dagger:dagger-android:2.37’ api ‘com.google.dagger:dagger-android-support:2.37’ kapt ‘com.google.dagger:dagger-android-processor:2.37’ // Dagger – Hilt implementation “com.google.dagger:hilt-android:2.37” kapt “com.google.dagger:hilt-android-compiler:2.37” *Thirdly add the classpath classpath “com.google.dagger:hilt-android-gradle-plugin:2.28-alpha” PS : if you re … Read more

Expected @HiltAndroidApp to have a value. Did you forget to apply the Gradle Plugin?

I just hit this problem this morning. Do you have anything in your build.gradle that adds arguments to the annotationProcessOptions? For example: android { … defaultConfig { … javaCompileOptions { annotationProcessorOptions { arguments = [“room.schemaLocation”: “$projectDir/schemas”.toString()] } } } } If so, try changing from “arguments =” to “arguments +=”, as just using equals overwrites … Read more

Plugin [id: ‘dagger.hilt.android.plugin’] was not found in any of the following sources

I am late for the answer. I was also facing the same problem in Android Studio Bumblebee because of the new Gradle syntax for adding dependencies at the project level. For adding Dagger Hilt in project-level you can use the following syntax: id ‘com.google.dagger.hilt.android’ version ‘2.41’ apply false At the time of writing this, the … Read more