[英]deep-linking not working after the app on production
I created my app with react-native expo and added deep-linking and I tested the deep-linking on develop and on simulator and it is working fine "npx uri-scheme open myapp://orders --android" but when try to open this "https://myschema.com/orders" on my android device through chrome not open the app the app.json is我使用 react-native expo 创建了我的应用程序并添加了深度链接,我在开发和模拟器上测试了深度链接,它工作正常“npx uri-scheme open myapp://orders --android”但是当尝试打开它时我的 android 设备上的“https://myschema.com/orders”无法通过 chrome 打开应用程序 app.json 是
{
"expo":{
"scheme": "myapp",
"android": {
//........
"intentFilters": [
{
"action": "VIEW",
"autoVerify": true,
"data": [
{
"scheme": "https",
"host": "myapp.com",
"pathPrefix": "/"
}
],
"category": [
"BROWSABLE",
"DEFAULT"
]
}
]
}
}
}
Add this for test ios添加此用于测试 ios
{
"scheme": "myapp",
"host": "*",
"pathPrefix": "/"
}
Your new code will be like:您的新代码将如下所示:
{
"expo":{
"scheme": "myapp",
"android": {
//........
"intentFilters": [
{
"action": "VIEW",
"autoVerify": true,
"data": [
{
"scheme": "https",
"host": "myapp.com",
"pathPrefix": "/"
},
{
"scheme": "myapp",
"host": "*",
"pathPrefix": "/"
}
],
"category": [
"BROWSABLE",
"DEFAULT"
]
}
]
}
}
}
ios => after build ipa
for test ios run this link in your browser phone when app installed: myapp:// ios =>在构建
ipa
进行测试 ios 安装应用程序后,在您的浏览器手机中运行此链接:myapp://
android => after build apk
for test android send in this link in message (email, whatsapp, ...) and click link for test (after installed app) android =>在构建
apk
以进行测试 android 在此链接中发送消息(电子邮件,whatsapp,...)并单击链接进行测试(安装应用程序后)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.