Can I push a new UIViewController from react-native to Objective-C Native bridge? I want to run the native screen from react-native. I don't want to implement native UI to a react-native component.
1 Answer
If I understand your question correctly you want to display your own UIViewController in the react-native app. So to implement this create a new NativeModule on the native ios side and access it on the react-native side. You can check how to do that here
Then you can call a function on this module. Then to present your UIViewController you need to access rootViewController as shown in the code below:
UIViewController *rootViewController = [UIApplication sharedApplication].delegate.window.rootViewController;
[rootViewController presentViewController:yourViewController animated:YES completion:nil];
So in this way, you can present your own UIViewController.