@@ -8,14 +8,17 @@ plugins {
8
8
check. dependsOn ' assembleDebugAndroidTest'
9
9
10
10
android {
11
- compileSdkVersion 33
11
+ compileSdk 33
12
12
13
13
defaultConfig {
14
14
applicationId " com.google.samples.quickstart.crash"
15
- minSdkVersion 19
16
- targetSdkVersion 33
15
+ minSdk 21 // minSdk would be 19 without compose
16
+ targetSdk 33
17
17
versionCode 1
18
18
versionName " 1.0"
19
+ vectorDrawables {
20
+ useSupportLibrary true
21
+ }
19
22
testInstrumentationRunner ' androidx.test.runner.AndroidJUnitRunner'
20
23
}
21
24
@@ -33,6 +36,22 @@ android {
33
36
34
37
buildFeatures {
35
38
viewBinding = true
39
+ compose true
40
+ }
41
+ compileOptions {
42
+ sourceCompatibility JavaVersion . VERSION_1_8
43
+ targetCompatibility JavaVersion . VERSION_1_8
44
+ }
45
+ kotlinOptions {
46
+ jvmTarget = ' 1.8'
47
+ }
48
+ composeOptions {
49
+ kotlinCompilerExtensionVersion ' 1.3.0'
50
+ }
51
+ packagingOptions {
52
+ resources {
53
+ excludes + = ' /META-INF/{AL2.0,LGPL2.1}'
54
+ }
36
55
}
37
56
}
38
57
@@ -41,6 +60,8 @@ dependencies {
41
60
implementation project(" :internal:chooserx" )
42
61
implementation ' com.google.android.material:material:1.6.1'
43
62
implementation " androidx.activity:activity-ktx:1.5.1"
63
+ implementation " androidx.lifecycle:lifecycle-viewmodel-ktx:2.5.1"
64
+ implementation ' androidx.lifecycle:lifecycle-runtime-ktx:2.5.1'
44
65
45
66
// Import the Firebase BoM (see: https://firebase.google.com/docs/android/learn-more#bom)
46
67
implementation platform(' com.google.firebase:firebase-bom:30.4.1' )
@@ -55,9 +76,18 @@ dependencies {
55
76
// For use in the CustomKeySamples -- for testing Google Api Availability.
56
77
implementation ' com.google.android.gms:play-services-base:18.1.0'
57
78
79
+ // Jetpack Compose
80
+ implementation " androidx.compose.ui:ui:$compose_version "
81
+ implementation " androidx.compose.material:material:$compose_version "
82
+ implementation " androidx.compose.ui:ui-tooling-preview:$compose_version "
83
+ implementation ' androidx.activity:activity-compose:1.5.1'
84
+
58
85
testImplementation ' junit:junit:4.13.2'
59
86
androidTestImplementation ' androidx.test.espresso:espresso-core:3.4.0'
60
87
androidTestImplementation ' androidx.test:rules:1.4.0'
61
88
androidTestImplementation ' androidx.test:runner:1.4.0'
62
89
androidTestImplementation ' androidx.test.ext:junit:1.1.3'
90
+ androidTestImplementation " androidx.compose.ui:ui-test-junit4:$compose_version "
91
+ debugImplementation " androidx.compose.ui:ui-tooling:$compose_version "
92
+ debugImplementation " androidx.compose.ui:ui-test-manifest:$compose_version "
63
93
}
0 commit comments