11// NOTE: this project uses Gradle Kotlin DSL. More common build.gradle instructions can be found in
22// the main README.
33plugins {
4- id(" com.android.application" )
4+ id(" com.android.application" )
5+ id(" org.jetbrains.kotlin.android" )
6+ id(" org.jetbrains.kotlin.plugin.compose" )
7+ id(" org.jetbrains.compose" )
8+ id(" com.google.gms.google-services" )
9+ id(" kotlin-kapt" ) // ← kapt drives annotation processors
510}
611
712android {
13+ namespace = " com.firebase.uidemo"
814 compileSdk = Config .SdkVersions .compile
915
10- namespace = " com.firebase.uidemo"
11-
1216 defaultConfig {
13- minSdk = Config .SdkVersions .min
14- targetSdk = Config .SdkVersions .target
15-
16- versionName = Config .version
17- versionCode = 1
18-
17+ minSdk = Config .SdkVersions .min
18+ targetSdk = Config .SdkVersions .target
19+ versionName = Config .version
20+ versionCode = 1
21+ multiDexEnabled = true
1922 resourcePrefix(" fui_" )
2023 vectorDrawables.useSupportLibrary = true
2124 }
2225
23- defaultConfig {
24- multiDexEnabled = true
25- }
26-
2726 buildTypes {
28- named( " release" ).configure {
27+ release {
2928 // For the purposes of the sample, allow testing of a proguarded release build
3029 // using the debug key
3130 signingConfig = signingConfigs[" debug" ]
32-
3331 postprocessing {
34- isRemoveUnusedCode = true
32+ isRemoveUnusedCode = true
3533 isRemoveUnusedResources = true
36- isObfuscate = true
37- isOptimizeCode = true
34+ isObfuscate = true
35+ isOptimizeCode = true
3836 }
3937 }
4038 }
4139
42- lint {
40+ compileOptions {
41+ sourceCompatibility = JavaVersion .VERSION_17
42+ targetCompatibility = JavaVersion .VERSION_17
43+ }
44+
45+ buildFeatures {
46+ viewBinding = true
47+ compose = true
48+ }
49+
50+ lint {
4351 // Common lint options across all modules
4452
4553 disable + = mutableSetOf (
@@ -59,16 +67,7 @@ android {
5967 abortOnError = true
6068
6169 baseline = file(" $rootDir /library/quality/lint-baseline.xml" )
62- }
63-
64- compileOptions {
65- sourceCompatibility = JavaVersion .VERSION_17
66- targetCompatibility = JavaVersion .VERSION_17
67- }
68-
69- buildFeatures {
70- viewBinding = true
71- }
70+ }
7271}
7372
7473dependencies {
@@ -80,23 +79,33 @@ dependencies {
8079 implementation(project(" :database" ))
8180 implementation(project(" :storage" ))
8281
82+ implementation(Config .Libs .Misc .glide)
83+ kapt(Config .Libs .Misc .glideCompiler)
84+
8385 implementation(Config .Libs .Provider .facebook)
8486 // Needed to override Facebook
85- implementation(Config .Libs .Androidx .cardView)
87+ implementation(Config .Libs .Androidx .cardView)
8688 implementation(Config .Libs .Androidx .customTabs)
87-
88- implementation(Config .Libs .Misc .glide)
89- annotationProcessor(Config .Libs .Misc .glideCompiler)
90-
9189 // Used for FirestorePagingActivity
9290 implementation(Config .Libs .Androidx .paging)
9391
9492 // The following dependencies are not required to use the Firebase UI library.
9593 // They are used to make some aspects of the demo app implementation simpler for
9694 // demonstrative purposes, and you may find them useful in your own apps; YMMV.
95+
9796 implementation(Config .Libs .Misc .permissions)
9897 implementation(Config .Libs .Androidx .constraint)
9998 debugImplementation(Config .Libs .Misc .leakCanary)
99+
100+ val composeBom = platform(" androidx.compose:compose-bom:2025.02.00" )
101+ implementation(composeBom)
102+ androidTestImplementation(composeBom)
103+
104+ implementation(" androidx.compose.material3:material3" )
105+ implementation(" androidx.activity:activity-compose:1.10.0" )
106+ implementation(" androidx.lifecycle:lifecycle-viewmodel-compose:2.8.5" )
107+ debugImplementation(" androidx.compose.ui:ui-tooling" )
108+ releaseImplementation(" androidx.compose.ui:ui-tooling-preview" )
100109}
101110
102- apply (plugin = " com.google.gms.google-services " )
111+ kapt { correctErrorTypes = true } // optional but avoids some kapt warnings
0 commit comments