android: add dependencies for Material 3 and Compose

This commit is contained in:
Colin Edwards 2023-12-22 13:05:39 -06:00
parent d9bbe39f48
commit 2638396df5
2 changed files with 29 additions and 0 deletions

View File

@ -1,5 +1,6 @@
plugins { plugins {
id("com.android.application") id("com.android.application")
id("org.jetbrains.kotlin.android")
} }
android { android {
@ -12,10 +13,18 @@ android {
targetSdk = 30 targetSdk = 30
versionCode = 1 versionCode = 1
versionName = "1.0" versionName = "1.0"
vectorDrawables {
useSupportLibrary = true
}
} }
buildFeatures { buildFeatures {
aidl = true aidl = true
compose = true
}
composeOptions {
kotlinCompilerExtensionVersion = "1.5.4"
} }
buildTypes { buildTypes {
@ -31,8 +40,27 @@ android {
sourceCompatibility = JavaVersion.VERSION_1_8 sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8
} }
kotlinOptions {
jvmTarget = "1.8"
}
packaging {
resources {
excludes += "/META-INF/{AL2.0,LGPL2.1}"
}
}
} }
dependencies { dependencies {
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.6.2")
implementation(platform("androidx.compose:compose-bom:2023.10.01"))
implementation("androidx.compose.material3:material3")
implementation("androidx.activity:activity-compose:1.8.2")
// Android Studio Preview support
implementation("androidx.compose.ui:ui-tooling-preview")
debugImplementation("androidx.compose.ui:ui-tooling")
debugImplementation("androidx.compose.ui:ui-test-manifest")
implementation("androidx.appcompat:appcompat:1.6.1") implementation("androidx.appcompat:appcompat:1.6.1")
} }

View File

@ -1,4 +1,5 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules. // Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins { plugins {
id("com.android.application") version "8.1.2" apply false id("com.android.application") version "8.1.2" apply false
id("org.jetbrains.kotlin.android") version "1.9.20" apply false
} }