I am trying to run create-react-native-app on expo app in android.
Firstly ,I created the project by writing command
create-react-native-app t
In my case the firewall settings alone didn't do it. My issue was that VirtualBox network devices were taking priority and the Expo host was starting on the wrong network.
On windows you can run ipconfig and look at the network adapters you have. npm/yarn start seems to take whatever shows up first in that list.
I found out about this from here: https://github.com/react-community/create-react-native-app/issues/60
If you don't need the other network adapters in the list, you can disable them in the Network Connections interface of the Control Panel.
If you need to use those connections and have Expo work then to solve the issue I followed this process:
- Goto Control Panel > Network and Internet > Network Connections
- Right click the desired connection (Higher Priority Connection)
- Click Properties > Internet Protocol Version 4
- Click Properties > Advanced
- Uncheck 'Automatic Metric'
- Enter 10 in 'Interface Metric'
- Click OK
Repeat for the Lower Priority Connection, but this time put 20 into the 'Interface Metric'
You'll now use the higher priority connection as a default.