I'm running on Android device, and when I start the app it won't pass the splash screen. If I switch to another app and come back, it runs correctly.
By putting some logs in the SplashActivity onResume, I found out it doesn't pass this condition on startup:
if (NavigationApplication.instance.isReactContextInitialized()) {
NavigationApplication.instance.getEventEmitter().sendAppLaunchedEvent();
return;
}
Here's my MainActivity:
public class MainActivity extends SplashActivity {
@Override
public View createSplashLayout() {
View view = new View(this);
view.setBackgroundColor(Color.CYAN);
return view;
}
}
And my MainApplication:
public class MainApplication extends NavigationApplication {
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new VectorIconsPackage(),
new RCTCameraPackage(),
new ReactNativeDialogsPackage()
);
}
@Override
public String getJSMainModuleName() {
return "artifacts/index";
}
@Override
public boolean isDebug() {
return BuildConfig.DEBUG;
}
@Override
public List<ReactPackage> createAdditionalReactPackages() {
return getPackages();
}
}
Just found out it's the same as #963. The bug only occurs with remote js debug enabled and hot reload turned off.
I'm getting this bug regardless of dev settings
iOS
version 0.48.4 as recommended by someone in another issue
Same here, exact the same issue
[email protected]
[email protected]
[email protected]
[email protected]
Easy to reproduce.
Download and prepare (npm install) https://github.com/wix/react-native-navigation-bootstrap
It works when execute from cmd with "react-native run-android" but fails when "remote debug js" (open chrome tab) is active or use visual studio code and react native tool.
This don't happend without react native navigation, so it seems to be related to a vs code and react native navigation conflict.
Same issue having here on Android only
"react": "^16.3.0-alpha.1",
"react-native": "0.54.0",
"react-native-navigation": "^1.1.398"
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
If you believe the issue is still relevant, please test on the latest version and report back. Thank you for your contributions.
The issue has been closed for inactivity.
Most helpful comment
Same issue having here on Android only