Summary: A very basic app with a scrolling list backed by a static data source. It also covers two bases that we hadn't before: Sections and Kotlin; the latter being the better choice for a modern Android tutorial anyway. Missing right now: BUCK support (likely not going to come anytime soon due to the kapt limitations), the actual Flipper plugin integration (that's up next). Reviewed By: jknoxville Differential Revision: D15166195 fbshipit-source-id: 3cfaa1d243548279cabc4f244c13363f1bcaa36c
63 lines
1.7 KiB
Groovy
63 lines
1.7 KiB
Groovy
/*
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the LICENSE file
|
|
* in the root directory of this source tree.
|
|
*/
|
|
|
|
apply plugin: 'com.android.application'
|
|
apply plugin: 'kotlin-android'
|
|
apply plugin: 'kotlin-android-extensions'
|
|
apply plugin: 'kotlin-kapt'
|
|
|
|
android {
|
|
compileSdkVersion 28
|
|
|
|
|
|
defaultConfig {
|
|
applicationId "com.facebook.flipper.sample.tutorial"
|
|
minSdkVersion 23
|
|
targetSdkVersion 28
|
|
versionCode 1
|
|
versionName "1.0"
|
|
}
|
|
|
|
compileOptions {
|
|
targetCompatibility = JavaVersion.VERSION_1_8
|
|
sourceCompatibility = JavaVersion.VERSION_1_8
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
minifyEnabled false
|
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
dependencies {
|
|
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$KOTLIN_VERSION"
|
|
implementation 'androidx.appcompat:appcompat:1.0.2'
|
|
implementation 'androidx.core:core-ktx:1.0.1'
|
|
|
|
// Flipper
|
|
// For simplicity, we use Flipper for both debug and release builds here.
|
|
// Check out the "sample" app to see how to separate your build flavors.
|
|
implementation project(':android')
|
|
implementation deps.soloader
|
|
|
|
// Litho
|
|
implementation deps.lithoCore
|
|
implementation deps.lithoWidget
|
|
implementation deps.lithoAnnotations
|
|
implementation deps.lithoSectionsAnnotations
|
|
implementation deps.lithoFresco
|
|
implementation deps.lithoSectionsCore
|
|
implementation deps.lithoSectionsDebug
|
|
implementation deps.lithoSectionsWidget
|
|
implementation deps.fresco
|
|
kapt deps.lithoProcessor
|
|
kapt deps.lithoSectionsProcessor
|
|
}
|