Reputation: 674
I have been trying to render localhost:3000 (React app) on my phone. I have tried the following,
npm start --host 0.0.0.0
I am running localhost on my MacBook. My colleague who has a Windows machine is also facing similar issues.
Upvotes: 0
Views: 189
Reputation: 371168
Make sure that the wifi network's wireless settings do not prevent local clients from connecting to each other. There is a setting often called "Wireless Isolation" which is pretty common - enabling this results in clients only being able to connect to the outside internet, but not to anything else (such as other wifi clients) on the network. While this is useful from a security perspective when the network administrator doesn't know whether the devices that want to connect are trustworthy, it blocks network functionality. Go into the router's settings and turn this off if it's on.
Upvotes: 0