Can’t view my app running on the desktop in the expo client


#1

Hi
I have a react-native app running on the laptop and when I try to view it on iPhone X using QR code reader of the phone’s camera I get the message “This is taking much longer than it shoul. You may want to check your internet connectivity “
Please note, both the phone and computer are running on the same private WiFi network and I could successfully ping from both to the other.
Any help is greatly appreciated


#2

Hi @gregorypro - have you tried using exp start --lan? This will serve the project over your local wireless network rather than making a round trip to expo’s servers and back (the default option).


#3

Thank you very much @esamelson. Sorry, i’m a newbie to expo. Right now, I’m using “npm start” to start the app on the laptop, following the expo mobile QR reader to load the app into the phone…
installed expo using “npm install -g exp” and ran “exp start --lan”. I’ve even tried the URL route “exp://…” instead of the QR reader.
The result is the same. What should I try next?


#4

Have you tried sending yourself a text message with the right URL? This can be done by running npm start pressing the letter key s configuring the right number (with area and land code) and then pressing enter to send the text message.

If the issue persists, can you try and setup a wifi hotspot with another phone, connect both your iPhone X and laptop to it and see if it works that way.

Thanks!


#5

@rauldeheer - thanks a lot.

Yes, I have done it many times - have sent app URL from “npm start” using ‘s’ (just like yo suggested) and also from “exp start --lan” and it always worked fine. i’ve also executed every suggestion given in the thread: - IMHO, the best thread on the issue
including setting the env var: REACT_NATIVE_PACKAGER_HOSTNAME and setting the right computer network adapter priority using Interface Metric on Win10.
In my case the phone and computer are on the same private WiFi network (192…), can ping each other, Network adapter priority is set right but still doesn’t work.
Nothing helped. Getting frustrated w/ the issue.


#6

Did you also try the other solution I’ve provided? I would like to know if that works.


#7

@rauldeheer
Have not tried the other solution since I don’t have a phone with the hotspot service. BTW, replacing exp by http (e.g. http://192…:1900 ) in a browser of the phone or another computer on the same private network worked! Per Troubleshooting section the suggestion is to open an issue on the Create React Native App repository with details about these steps and any other error messages you may have received.


#8

The issue is resolved by using Expo XDE.

Thanks all.


closed #9

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.