Tuesday, 31 August 2021

Is there a way to tell manifest merger not to add path data to intent-filter

I'm using navigation component and navigation graph for handling deeplinks. I've added deeplinks to my destinations like below

<deepLink app:uri="example://foo" />

Intent Filter documentation mentions:

If a filter specifies a scheme and an authority but no path, all URIs with the same scheme and authority pass the filter, regardless of their paths.

According to this, a uri like example://foo should match my deeplink. But manifest merger adds this line to my intent filter, even if don't add any path to my uri:

<data android:path="/" />

So only a example://foo/ is matched. Is there a way to tell manifest merger or navigation graph to remove this data element from my intent filter?



from Is there a way to tell manifest merger not to add path data to intent-filter

No comments:

Post a Comment