Feature Module - Android

Android App Bundle 

  • Distribution format for Android App 
  • We save up-to 15% file size saving on users device compared to universal APK. 
Advanced features of Android App Bundles that enable play feature delivery. 
Apis that we can use to deliver features conditionally or on demand, as well as multiple configuration options. 

How to configure your app for Play Feature Delivery 


Feature Modules requires devices to run Android Lollipop 5.0 or newer. 

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:dist="http://schemas.android.com/apk/distribution"
package="com.google.android.samples.playcore.picture">
<uses-feature android:name="android.hardware.camera" android:required="true" />

<dist:module
dist:onDemand="true"
dist:title="@string/module_title_name">
<dist:fusing dist:include="true" />
<dist:delivery>
<dist:install-time>
<dist:conditions>
<dist:min-api dist:value="21" />
<dist:max-api dist:value="29" />
<dist:device-feature dist:name="android.hardware.camera"/>
<dist:user-countries dist:exclude="false">
<dist:country dist:code="DE" />
<dist:country dist:code="GB" />
</dist:user-countries>
</dist:conditions>
</dist:install-time>
<dist:removable value="true" />
</dist:delivery>
</dist:module>

</manifest>

How to manage the on-demand feature module ?

The class that always handles calling the Play Store and notifying your app of the module's installation state is called SplitInstallManager. 


































Comments

Popular Posts