I cannot fetch anything from my local .NET webAPI (that's running on my computer) while using my react native app (Expo Go) that is "streamed" to my phone. The error I get is: TypeError: Network request failed
I am able to fetch other public test API's like "https://jsonplaceholder.typicode.com/todos/1" with my app.
The backend is also reachable via Postman and browser by every device in the network, when trying to get response from it.
This is my setup:
Figured a workaround. Not sure 100% but the issue could've been caused by having my mobile app running localy trying to reach an api call on the same local server (just like engr.ukairo suggested earlier). Even calling directly by ip didn't work.
I decided to try ngrok and it works. Worth it and doesn't take alot of time to configure.