App not loading in iOS

I am working with Ionic React to build a project out with Firebase. Currently, the app is working completely fine and as expected, but when I try to load it up in iOS, it never loads; just get a white loading screen. When I launch it in XCode, this is the output:

2021-08-16 19:28:44.905497-0500 App[44733:7842304] DiskCookieStorage changing policy from 2 to 0, cookie file: file:///Users/dgreen/Library/Developer/CoreSimulator/Devices/641C1A08-41C7-4EDA-BD68-74AF426169FE/data/Containers/Data/Application/B82C2A8D-8207-457B-B670-E57BABA62883/Library/Cookies/com.sevensandfifteens.binarycookies
2021-08-16 19:28:44.991592-0500 App[44733:7842304] screen parameters are unexpected: MGScreenClass1125x2436x3x495 SCREEN_TYPE(1125,2436,3,495)
2021-08-16 19:28:44.992487-0500 App[44733:7842304] screen parameters are unexpected: MGScreenClass1125x2436x3x495 SCREEN_TYPE(1125,2436,3,495)
2021-08-16 19:28:44.992677-0500 App[44733:7842304] screen parameters are unexpected: MGScreenClass1125x2436x3x495 SCREEN_TYPE(1125,2436,3,495)
2021-08-16 19:28:45.260235-0500 App[44733:7842304] KeyboardPlugin: resize mode - native
⚡️  Loading app at capacitor://localhost...
2021-08-16 19:28:45.396724-0500 App[44733:7842304] WF: === Starting WebFilter logging for process App
2021-08-16 19:28:45.396891-0500 App[44733:7842304] WF: _userSettingsForUser : (null)
2021-08-16 19:28:45.397035-0500 App[44733:7842304] WF: _WebFilterIsActive returning: NO
⚡️  WebView loaded
2021-08-16 19:29:15.390122-0500 App[44733:7844002] [] nw_protocol_get_quic_image_block_invoke dlopen libquic failed

Here is a link to the repository

Is it also failing if u run it as pwa on ios?

Have ubtried an empty project in capacitor on ios?

I’m not 100% sure how to test as a PWA, I’m new to Ionic. I am able to locally pull it up in Simulator after running ionic serve

I am able to get a freshly created Capacitor app running via npx cap run ios on a Simulator

Hi
from the code I can see you have a service worker setup, so that seems something all good.
And as you are using firebase, it can almost be as simple as deploying to firebase hosting.

This test helps you figuring out potential incompatibility of your web code with iOS in Safari browser.

Tom

I also verified that the app can run on Android, so it seems my issue may be iOS specific

wow, not sure why or how. but i threw my hands up, deleted the android and ios folders, re-ran ionic capacitor add {platform}, and now it’s working when I use ionic capacitor run ios -l --external

it still doesn’t work if I use npx cap run ios, but at least I’m getting somewhere

Now ionic capacitor run ios -l --external is not working

I remembered that I needed to add in GoogleService-Info.plist to work with firebase.

I’ve basically followed this tutorial except I haven’t added the @capacitor/push-notifications package since I am not using push notifications.

1 Like