Based from this site,
When an app makes use of Instant Apps
, that app is divided into one or
more feature modules, each of which is contained within a separate
feature APK file. Each feature consists of a specific area of
functionality within the app, typically involving one or more Activity
instances. The individual feature APKs are then bundled into an
instant app APK which is then uploaded to the Google Play Developer
Console.
This means that both the app and instant app modules serve as containers for the feature modules that make up the app. An app must contain at least one feature module and may also contain additional modules for other features.
The build.gradle
file for the instant app module, on the other hand, will use the com.android.instantapp
plugin to build separate feature APK files for the features referenced in the dependencies section. Note that feature dependencies are referenced using implementation project() declarations:
apply plugin: 'com.android.instantapp'
dependencies {
implementation project(':myappbase')
implementation project(':myappfeature')
}