Quantcast
Channel: Active questions tagged react-native+ios - Stack Overflow
Viewing all articles
Browse latest Browse all 16750

React Native: Expo app could not open my project

$
0
0

I am starting on a react native project but I have a problem with Expo opening my project on my iOS device. My devices are connected to the same wifi network. It takes very long to load and the message 'This is taking much longer than it should. You might want to check your internet connectivity' appears. After awhile more, an error occurs and I experienced 3 different types of error, with different errors occurring each time I try to reopen my project.

1st error: 'There was a problem running the requested app.'

2nd error: 'There was a problem loading the requested app. It looks like you may be using a LAN URL. Make sure your device is on the same network as the server or try using a tunnel.'

I tried using tunnel but it does not resolve the problem.

3rd error: A red screen appears with the following error:

Could not connect to development server.

Ensure the following:- Node server is running and available on the same network - run 'npm start' from react-native root- Node server URL is correctly set in AppDelegate- WiFi is enabled and connected to the same network as the Node Server

URL: http://192.168.1.210:19001/node_modules%5Cexpo%5CAppEntry.bundle?platform=ios&dev=true&minify=false&hot=false

ABI37_0_0facebook::ABI37_0_0React::JSIExecutor::defaultTimeoutInvoker(std::__1::function const&, std::__1::function, std::__1::allocator > ()>)ABI37_0_0facebook::ABI37_0_0React::JSIExecutor::defaultTimeoutInvoker(std::__1::function const&, std::__1::function, std::__1::allocator > ()>)5A83D0CF-8FB9-3727-8A32-012D20A47EC85A83D0CF-8FB9-3727-8A32-012D20A47EC85A83D0CF-8FB9-3727-8A32-012D20A47EC8409609CD-8410-38E1-BA5D-BDED609D2018409609CD-8410-38E1-BA5D-BDED609D2018CFRunLoopRunSpecificGSEventRunModalUIApplicationMainExponent876FB49A-BFBA-37BF-AD37-6FFC90F7F981

Here is what I found when I opened the AppDelegate file in my project directory:

/** * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */#import "AppDelegate.h"#import <React/RCTBridge.h>#import <React/RCTBundleURLProvider.h>#import <React/RCTRootView.h>@implementation AppDelegate- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{    RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions];  RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge                                                   moduleName:@"HelloWorld"                                            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];  return YES;}- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge{#if DEBUG  return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];#else  return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];#endif}@end

I have tried uninstalling and reinstalling node and expo, disabling firewall, initializing a new project and try to open it but all methods didn't work. Anybody knows what is the issue here? Thanks in advance!


Viewing all articles
Browse latest Browse all 16750

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>