Always getting white blank screen when running the app on the physical device in android case. Using react-native-navigation
can't able to detect the bug please help!
I have created a fresh react-native
project and integrated the react-native-navigation
library into it and when I am running the app in my physical device by running the command yarn run android
it runs but shows blank white screen in android. Once it runs successfully but now it won't.
Usually, we get a blank screen when the app is not connected to React Native development server. Make sure that you have started the development server in another terminal using npm start in project root folder. If dev server is running then dev server can be accessed locally over USB or over Wifi.
A blank or white screen occurs when React encounters a rendering error in a component (for example, trying to render obj. param when obj is undefined). You would probably think that when React encounters an error, the faulty component and descendants will unmount.
run react-native start in a separate terminal and then run react-native run-android.
i recently faced two kind of white screen problem
1.always showing white screen (due to bundling..) solutions is
react-native start
and then
react-native run-android
2.it shows white screen some particular seconds or suddenly always shows white screen in properly working app
due to app cache or traffic
solutions is
Androidmanifest.xml
android:usesCleartextTraffic="true"
I also faced same issue in the emulator. So the way I solved it is by going into Android settings - Apps - select the app, and force stop it. Then I tried opening the app again and it worked.
Before I did this, I removed the 'build' folder under /android/app/ and re-ran. Did not work.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With