electrode-native icon indicating copy to clipboard operation
electrode-native copied to clipboard

have ios ErnRunner configured to use localhost ip by default

Open romanlv opened this issue 5 years ago • 1 comments

This is more like a suggestion/question:

I find myself always changing /ios/../RunnerConfig.m to point to localhost instead of external ip NSString *const PackagerHost = @"127.0.0.1"

External ip keeps changing depending on current connection (wired/internal wifi/public wifi/home/vpn) it means that that ios app just stops finding development server and requires waiting for long ern run-ios to complete

Having it to point to 127.0.0.1 makes a lot of sense unless there are any reason not do ot it...

romanlv avatar Aug 29 '19 02:08 romanlv

Hi Roman, This is a change we introduced recently when adding support to iOS Runner to properly connect to metro through wifi when running on a physical device, and we just set it as the default mode. This wasn't a good move, we should instead infer IP to be used, at compile time of the iOS app, when we can know if the app is going to be run on a simulator or device, rather than baking the IP at the time of runner generation.
We will look into it, thanks for reporting this !

belemaire avatar Aug 30 '19 16:08 belemaire