I have setup Passwordless authentication for my react-native app, for that it required to setup firebase dynamic links which I did successfully.
And everything was working fine on both Platforms Android and iOS, but after I merged my branch with the master, it stopped working on iOS. Meaning I am receiving the email to SignIn but that link is not opening the iOS app but it is working on Android successfully.
I did the following steps to setup Dynamic Links for iOS:
- AppDelegate.m
#import "AppDelegate.h"
#import <React/RCTBridge.h>
#import <React/RCTBundleURLProvider.h>
#import <React/RCTRootView.h>
@import Firebase;
//Deep Linking RNavigation Docs
#import <React/RCTLinkingManager.h>
//Deep Linking RNavigation Docs
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions];
RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge
moduleName:@"realyze"
initialProperties:nil];
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
UIViewController *rootViewController = [UIViewController new];
rootViewController.view = rootView;
self.window.rootViewController = rootViewController;
[self.window makeKeyAndVisible];
[FIRApp configure];
return YES;
}
- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge
{
#if DEBUG
return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
#else
return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
#endif
}
//Deep Linking RNavigation Docs
- (BOOL)application:(UIApplication *)app openURL:(NSURL *)url
options:(NSDictionary<UIApplicationOpenURLOptionsKey,id> *)options
{
return [RCTLinkingManager application:app openURL:url options:options];
}
//Deep Linking RNavigation Docs
@end
Added Association Domains Capability In Xcode and in my Apple Developer Account for the particular App
Added TeamID to Firebase Console for the appID prefix.
Added these Firebase Authorized Domains: applinks:realyze.page.link activitycontinuation:realyze.page.link
Also added domains to an entitlements file
6.app-site-associations-file is also setup correctly
This setup worked for me before I merged my branch.
Help would be very much appreciated.
Thank you.