This repository was archived by the owner on Oct 23, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 32
Conditionally set HttpLink URI #98
Labels
Comments
Alright will handle this asap |
Well android does not really, except you are using an emulator. For real device its different, it is based on the ip of the wifi connection which changes every time it restarts. But I will have a fix for that |
Is |
@marktani - apparently, no. It has to do with proxying through with Expo. |
@DevanB did you end up finding a solution to this? |
@devomacdee unfortunately, no. I haven’t necessarily worked on it much too. The crux of the solution I proposed is figuring out the developer’s IP address when the env is development (don’t worry about production since that should be a separate url for a server). |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
There is an issue with fetch in React Native that prevents the usage of
localhost
.A proposed solution is to use
Platform.select
to set the ApolloClient'sHttpLink
uri to one of several options:Android apparently allows 10.0.2.2 to equal localhost, but I haven't confirmed this myself.
The text was updated successfully, but these errors were encountered: