android - Android Instant App URL 执行问题
问题描述
我创建了一个我认为是 android 即时应用程序。每当我通过 Android Studio 测试即时应用功能时,它都会按预期工作。我已按照说明生成用于将免安装应用链接到 URL 的关联文件,并将它们相应地放置在我的网站上。我已将签名包上传到 alpha 封闭测试轨道。我使用的 URL 将用于启动应用程序。但是,当我转到设置-> 谷歌-> 应用程序和通知并删除即时应用程序时,该链接不再有效,它会将我直接带到该网站。我不明白我做错了什么,因为我理解不需要预安装即时应用程序 URL 应该触发我假设 Play 商店发送捆绑包以加载到内存中(某种)。我认为我应该能够在不先安装它的情况下运行即时应用程序是否正确?任何帮助,将不胜感激。下面是我的清单文件。我认为这是正确的。
几乎相同的问题:单击链接时未启动 InstantApp
我已经尝试过该帖子中提到的解决方案。没有成功。
如果这个描述/问题很糟糕,请告诉我,我会努力让它变得更好。第二个帖子第一次被删除我想是因为它很烂?不知道。提前感谢社区的帮助。
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:dist="http://schemas.android.com/apk/distribution"
xmlns:tools="http://schemas.android.com/tools"
package="learn.instantapps">
<!-- The following declaration enables this module to be served instantly -->
<dist:module dist:instant="true"></dist:module>
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:targetSandboxVersion="2"
android:theme="@style/AppTheme">
<activity android:name="learn.instantapps.MainActivity">
<meta-data
android:name="default-url"
android:value="https://mysite/main" />
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter android:order="1">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:scheme="https"
android:host="my site"
android:path="/main" />
</intent-filter>
<intent-filter android:order="1">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:scheme="http"
android:host="my site"
android:path="/main" />
</intent-filter>
</activity>
</application>
</manifest>
解决方案
推荐阅读
- javascript - 如何在 WebStorm 中突出显示匹配的三元表达式运算符
- node.js - 无法使用 npm run start:server 启动我的节点服务器
- javascript - React 应用程序使用自定义 useRequest 钩子不断重新渲染
- docker - DOCKER - 左边的空间
- kubernetes - 如果 SHA 摘要不同,则 Airflow KubernetesPodOperator 图像拉取策略拉取
- css - 扩展嵌套的父级以对 SASS 中的公共参数进行分组
- javascript - 展示如果页面上存在特定的
- python-3.x - 如何使用 buildpack 混淆 Python 代码?
- python - 电报机器人将文本从图像发送回用户
- angular - Angular如何使用嵌套的ng-template测试嵌套组件?