import static de.fayard.refreshVersions.core.Versions.versionFor

plugins {
  id 'com.android.application'
  id "org.jetbrains.kotlin.android"
  id 'kotlin-kapt'
}

android {
  namespace 'com.airbnb.lottie.sample.compose'
  compileSdk 36
  defaultConfig {
    applicationId "com.airbnb.lottie.sample.compose"
    minSdk 21
    targetSdk 36
    versionCode 1
    versionName VERSION_NAME
    testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  }
  buildTypes {
    release {
      minifyEnabled false
      signingConfig signingConfigs.debug
      debuggable false
    }
  }
  kotlinOptions {
    freeCompilerArgs += [
        "-Xskip-prerelease-check",
        "-opt-in=androidx.compose.foundation.ExperimentalFoundationApi",
        "-opt-in=androidx.compose.material.ExperimentalMaterialApi",
        "-opt-in=kotlin.RequiresOptIn",
    ]
  }
  buildFeatures {
    compose true
    buildConfig true
  }
  composeOptions {
    kotlinCompilerExtensionVersion = versionFor(project, AndroidX.compose.compiler)
  }
  packagingOptions {
    exclude 'META-INF/AL2.0'
    exclude 'META-INF/LGPL2.1'
  }
}

kapt {
  correctErrorTypes = true
}

dependencies {
  implementation project(':lottie-compose')
  implementation libs.androidx.appcompat
  implementation libs.androidx.core.ktx
  implementation libs.androidx.activity.compose
  implementation libs.google.material
  implementation platform(libs.compose.bom)
  implementation libs.compose.ui
  implementation libs.compose.foundation
  implementation libs.compose.material
  implementation libs.compose.material.icons.extended
  implementation libs.compose.ui.tooling
  implementation libs.androidx.navigation.ui
  implementation libs.androidx.navigation.compose
  implementation libs.androidx.viewmodel.ktx
  // Need this to side load a Baseline Profile when Benchmarking
  implementation libs.profileinstaller


  implementation libs.kotlinx.coroutines.android

  implementation libs.dagger
  kapt libs.dagger.compiler

  implementation libs.retrofit
  implementation libs.retrofit.moshi
  implementation libs.coil.compose
  implementation libs.mavericks
  implementation libs.mavericks.compose

  debugImplementation libs.compose.ui.test.manifest

  androidTestImplementation libs.compose.ui.test.junit
}
