Other Stuff in the android
Closure
The android
closure has a testInstrumentationRunner
statement — we will explore that more in an upcoming chapter, to see how testing works.
The android
closure also has a buildTypes
closure. This provides specific configuration for different “build types”, such as debug
for development builds and release
for production builds. The defaults provided in the starter project are fine for many basic apps.
The compileOptions
and kotlinOptions
closures indicate that we want the Java and Kotlin compilers to generate JVM 1.8 bytecode. While JVM bytecode has advanced a lot since then, 1.8 is the newest that Android supports at this time.
Prev Table of Contents Next
This book is licensed under the Creative Commons Attribution-ShareAlike 4.0 International license.