Ionic 2 rc0: Showing White screen on Android device


#1

i updated my app from ionic 2 beta to ionic 2 rc0: manually it is perfectly working with “ionic serve” and “ionic serve --lab” but not working on emulator showing white screen by “running ionic run android”. i inspect that using chrome dev tool here is screen short.

Error: failed to load resources file:///android_asset/www/build/main.js

here is screen short

need help senior!

Thanks!


#2

Is there anything printed out in the console? if there’s an error building, it will print out there


#3

Upgrade your RC0 to RC1, it (REALLY) is a minor change and fixes many bugs that could be related to your white screen.


#4

just showing failed to load resource.

another thing is if i create another tutorial or blank app run that in
device those are working perfectly no white screen issue at there.

please guide if that is build problem.

thanks!


#5

I’m pretty sure you’ve got some build errors while running ionic run android. This error typically means your main.js file wasn’t build and included at all, most probably because of some ngc error. Please check the build logs when running to your device (in your terminal), because that’s where those errors usually show up.


#7

thanks sir for reply!

now on ionic serve i am getting error: Failed to load resource: the server responded with a status of 404 (Not Found)

and .tmp directory not updating can we delete that or not ?


#8

Please again check your terminal, because it’s probably signaling why it’s failing. Do you have any build logs whatsoever?


#10

yeah now on terminal when i run “ionic run android” facing these…


#11

Start by fixing these issues. I suppose you’re using the Observable class but aren’t importing it (yet). If you’re free of these errors, please come back and we can help you further :slight_smile:


#12

i have upgraded the app to rc1 and now solved those error and launched that on device but there are no log errors on terminal and till displaying white screen on device.


#13

These logs only point to the build process for the device. Please check if there aren’t any build errors on the angular/ionic stuff. You can find those directly above your android build logs. These logs are the first ones you see when you hit the ionic run command.


#14

As you can see there is no error at there after running the “ionic run android”.


#15

waiting for help! please guide me where is i am doing wrong?


#16

Okay, thats weird indeed. It doesn’t work with ionic serve now either? What error logs does the console give you now (not the terminal)


#17

“Ionic serve” is working perfectly but “ionic run android” not working … what will be the issue i am facing that from 2days …


#18

Did you already try it on a different device? And what does the console of the device say when you make an entirely clean build? Did you already try to remove the platform and build it again?


#19

i did all except the removing the platform and building again. how to do that?


#20

cordova platform remove android --> then readd it back. Just run ionic run android and it will automatically put the android platform back in.


#21

Thanks a lot after removing the android platform and running “ionic run android” again solved the problem!


#22

Glad it’s solved. Good luck!