iOS App on production device is running locally at localhost:8080

My Ionic build seems to be running locally in the emulated iOS device at localhost:8080,

All of my XMLHttpRequests fail with

http://localhost:8080/Users/xxxx/Library/Developer/CoreSimulator/Devices/EF50E90D-806A-472A-918D-E8A39443B241/data/Containers/Bundle/Application/50958C20-C80B-462F-BA41-4F650A68611E/LendIt.app/www/www.xxxx.io/xxxx/xxxx/xxxx/xxxx/xxxx/xxxx.php

Furthermore, I am using location services and it also responded with

[blocked] Access to geolocation was blocked over insecure connection to http://localhost:8080.

My XMLHttpRequest is similar to

var xhr = new XMLHttpRequest();
xhr.open(“GET”,“https://www.google.com”,false);
xhr.send();

Note that android works fine. Ionic version is 3.18.0. The app was built using

ionic cordova build ios --prod --release

If there is anymore I can provide, please let me know. This is causing a lot of stress especially since it doesn’t make sense to me why the iOS app is not running like it normally does.

Thanks

Im having the same issue! any updates on this matter?

Did you ever figure this out? I’m having the same issue…

so it seems that since the move in iOS to use WKWebView, all iOS Ionic apps now run off a local server by default.

The best option is to implement CORS server side.

as a quick fix though I’ve just added this into config.xml to revert back to the UIWebView until I can get that sorted.

<preference name="CordovaWebViewEngine" value="CDVUIWebViewEngine" />

Hey @digitalbath did you manage to find another fix for the problem?

I am having same issues when I use latest beta. Any updates?