在Google Chrome浏览器中反应本机Android深层链接

问题描述

大家好,我在android中有奇怪的深层链接行为,我创建了route并给了他们path,uriPrefix和其他所有准备。 所以我通过adb测试了

>adb shell am start -W -a android.intent.action.VIEW -d "dapurq://auth/register" com.dapurq

它与该输出完美配合

Starting: Intent { act=android.intent.action.VIEW dat=dapurq://auth/register pkg=com.dapurq }
Warning: Activity not started,intent has been delivered to currently running top-most instance.
Status: ok
LaunchState: UNKNowN (0)
Activity: com.dapurq/.MainActivity
TotalTime: 0
WaitTime: 5
Complete

但是当我在模拟器浏览器(谷歌浏览器)中键入内容时,它不起作用,而是浏览器搜索地址

enter image description here

解决方法

这是答案,我为缺乏文档阅读感到as愧

所以我们不能直接访问深层链接,它应该包装在意图中

<a href="intent://beli/userprofile/someurl #Intent;scheme=dapurq;package=com.package;S.browser_fallback_url=https%3A%2F%2Fdapurq.id%2Fnoapps;end"> Deelink</a>