In order to prepare for Instant Apps, I split my app into multiple modules with one activity each. Each activity launches another activity by throwing an intent with the destination URL (as opposed to class name).
The issue here is that the activity chooser shows up after each startActivity
call. Users can select "always" for each activity, but doing it for 25 activities, navigating within the app will be a poor experience.
I can have autoVerify=true
in the Manifest. This will help API level 23+. But any ideas how to support the older versions? InstantApp is supported until SDK 21, and my regular app is on API 19.
You'll have to add the DEFAULT
category to your intent filter like this:
<intent-filter android:autoVerify="true">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
...
</intent-filter>
See this sample for more context.