I've been using React Native & Branch.io successfully for awhile and it's great. However, I would like to be able to handle non-Branch deeplinks as well. For instance, if my domain name is https://example.com, I'd like my app to be opened when opening, say, https://example.com/my-items. I've been trying to make it work with no luck. I read many, many GitHub issues and SO questions. To repeat, https://example.app.link (i.e. Branch urls/universal links) work without any issues.
Basically, when I click on https://example.com/my-items , my website opens in Safari. The "Open with XYZ" iOS modal does not show up, and I am not taken to the app.
Here's what I've already tried:
0) Went through https://facebook.github.io/react-native/docs/linking and https://hackernoon.com/react-native-deep-linking-for-ios-and-android-d33abfba7ef3
1) Made sure I serve https://example.com/apple-app-site-association (and verified it with https://branch.io/resources/aasa-validator/ ) as JSON and is publicly available.
2.1) I also tried with app.link associated d
3) For the sake of debugging, I even made the following in AppDelegate.m (normally I check via [RCTLinkingManager application:application openURL:url options:options]
etc)
- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url options:(NSDictionary<UIApplicationOpenURLOptionsKey,id> *)options {
return YES;
}
- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity
restorationHandler:(void (^)(NSArray * _Nullable))restorationHandler
{
return YES;
}
4) I tried on the device itself (using iMessages, Notes, Safari). I also turned off remote debugging (as noted here)
Relevant versions:
XCode: Version 10.2.1 (10E1001)
iOS: 12.4.1
react-native: 0.60.5
react-native-branch: 3.0.0^
https://example.com/apple-app-site-association
{
"applinks": {
"apps": [],
"details": [
{
"appID": "<MyTeamID-censored>.<My-Bundle-Identifier-censored>",
"paths": [
"/verify-email*",
"/notifications/borrower-request*",
"/notifications/request-confirmed*",
"/messages/*",
"/verification",
"/my-items",
"/my-rentals",
"/dashboard*"
]
}
]
}
}