从Web到PWA的深层链接(独立版) [英] Deep linking from Web to PWA (Standalone Version)
本文介绍了从Web到PWA的深层链接(独立版)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个Web应用程序,由于PWA标准,它可以作为独立应用程序安装在主屏幕中。
I have a web app that it can be installed as standalone application in the homescreen thanks to PWA standard.
当用户忘记密码时,会发送一封电子邮件
When a user forget his password, a email is sent to him with a link to reset the password.
问题是:
我可以深入链接到他吗?已经安装的独立版本,而不是Chrome浏览器中的Web应用程序?我想实现此行为:
Can I deep-link to the already-installed standalone version instead of the web application in chrome browser? I'd like to achieve this behaviour:
- 用户点击来自gmail应用程序的电子邮件链接。
- OS检查链接是否与系统中预先注册的任何网址架构匹配(这是我目前不知道是否可以通过网络进行的步骤)
- 如果找到,打开独立版本。否则,请打开浏览器。
预先感谢!
干杯
推荐答案
在json 此处。清单的相关部分是 intent_filters
There is an example of describing intent filters in json here. The relevant section of the manifest is intent_filters
{
"manifest_package": "org.chromium.webapk.test",
"scope_url": "https://pwa.rocks/",
"intent_filters": {
"scope_url_scheme": "https",
"scope_url_host": "pwa.rocks",
"scope_url_path": "/"
},
"start_url": "https://pwa.rocks/",
"display_mode": "standalone",
"orientation": "portrait",
"theme_color": "2147483648L",
"background_color": "2147483648L",
"icon_urls_and_icon_murmur2_hashes": "http://www.pwa.rocks/icon1.png 0 http://www.pwa.rocks/icon2.png 0",
"web_manifest_url": "https://pwa.rocks/pwa.webmanifest",
"version_code": "1",
"version_name": "1.0",
"bound_webapk": {
"runtime_host": "org.chromium.chrome",
"runtime_host_application_name": "Chromium"
}
}
这篇关于从Web到PWA的深层链接(独立版)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文