uts_nabila_202310715066/app/build.gradle.kts
2025-11-07 13:54:58 +07:00

78 lines
2.4 KiB
Plaintext

plugins {
alias(libs.plugins.android.application)
alias(libs.plugins.kotlin.android)
// 1. TAMBAHKAN PLUGIN COMPOSE COMPILER DI SINI
alias(libs.plugins.compose.compiler)
}
android {
namespace = "com.example.kalkulatorbmi"
compileSdk = 36
defaultConfig {
applicationId = "com.example.kalkulatorbmi"
minSdk = 24
targetSdk = 36
versionCode = 1
versionName = "1.0"
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary = true
}
}
buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}
kotlinOptions {
jvmTarget = "11"
}
buildFeatures {
// 2. AKTIFKAN COMPOSE DI SINI (INI MASIH DIPERLUKAN)
compose = true
}
// 3. HAPUS BLOK composeOptions YANG LAMA
// composeOptions {
// kotlinCompilerExtensionVersion = "1.5.11" // <- HAPUS BLOK INI
// }
packaging {
resources {
excludes += "/META-INF/{AL2.0,LGPL2.1}"
}
}
}
dependencies {
// Dependensi lain tetap sama...
implementation(libs.androidx.core.ktx)
implementation(platform("androidx.compose:compose-bom:2024.05.00"))
implementation("androidx.compose.ui:ui")
implementation("androidx.compose.ui:ui-graphics")
implementation("androidx.compose.ui:ui-tooling-preview")
implementation("androidx.compose.material3:material3")
implementation("androidx.activity:activity-compose:1.9.0")
implementation("androidx.navigation:navigation-compose:2.7.7")
implementation(libs.androidx.constraintlayout)
implementation("androidx.compose.material:material-icons-extended")
// Dependensi untuk pengujian
testImplementation(libs.junit)
androidTestImplementation(libs.androidx.junit)
androidTestImplementation(libs.androidx.espresso.core)
androidTestImplementation(platform("androidx.compose:compose-bom:2024.05.00"))
androidTestImplementation("androidx.compose.ui:ui-test-junit4")
debugImplementation("androidx.compose.ui:ui-tooling")
debugImplementation("androidx.compose.ui:ui-test-manifest")
}