Android意图过滤器无法使用pathPrefix / pathPattern找到与我的通用链接的正确匹配

问题描述

我试图让我的react-native应用程序仅在遇到以下链接时才在Android上打开: https://example.co/something/reset-password?key=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2MDIyNzEwMjYsInR5cGUiOiJ1c2VycyIsInV1aWQiOiIzYmVhMDM2Ni01MmE4LTU2YTgtYWQ2OS1iNjlhM2VlMmMxNWEifQ.urvZ41ivWPJRl_LtyLXtSqSHzaE5XdClxSvJC9AL-vI

something可以更改的地方。还有令牌。

我尝试过但没有奏效的东西:

<data android:scheme="https" android:host="example.co" android:pathPattern="/.*/reset-password?key=.*"/>

<data android:scheme="https" android:host="example.co" android:pathPattern="/.*/reset-password\?key=.*"/>

<data android:scheme="https" android:host="example.co" android:pathPattern="/.*/reset-password\\?key=.*"/>

<data android:scheme="https" android:host="example.co" android:pathPattern="/.*/reset-password\\\?key=.*"/>

<data android:scheme="https" android:host="example.co" android:pathPrefix="/.*/reset-password" />

我只能使用此链接打开带有该链接的应用程序 <data android:scheme="https" android:host="example.co" /> 但这不是我们想要的。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)