【发布时间】:2021-08-28 16:20:50
【问题描述】:
我的 Flutter 应用程序上的 iOS 通用链接似乎无法正常工作。以下是我设置通用链接的步骤:
-
安装flutteruni_links package
-
上传了以下 apple-app-site-association(包含团队 ID 和包标识符的实际值):
{ "applinks": { "details": [ { "appID": "xxxxxxx.com.bundleIdentifier", "paths": [ "*" ], "appIDs": ["xxxxxxx.com.bundleIdentifier"], "components": [ { "/": "*" } ] } ] }} -
通过 https://branch.io/resources/aasa-validator/ 验证的 apple-app-site-association 文件(值得注意的是,我无法使用 Apple 的 appsearch-validation-tool 进行验证 - 收到错误:“无法提取通用链接所需的信息。”)
-
在我的项目功能中添加了关联域: screenshot from xcode
使用/usr/bin/xcrun simctl openurl 打开或单击我的移动设备上的 url(从 notes 应用程序尝试)仍会在 safari 中打开 url 而不是打开应用程序。
我可能会错过什么?
【问题讨论】:
-
你使用的服务器是HTTP还是HTTPS?
-
@Shahar HTTPS,并确认内容类型 json
-
将
mode=developer添加到您的项目功能以绕过苹果CDN。您还可以在您的设备上生成系统诊断以获取日志文件wwt.com/article/… -
@Paulw11 感谢您的提示!我将
?mode=developer添加到我的项目功能中,并根据文章运行分析。我的应用程序甚至没有出现在swcutil_show.txt中,所以我猜这意味着该应用程序甚至没有在寻找 AASA 文件?对我可能错过的东西真的傻眼了。
标签: ios flutter deep-linking ios-universal-links