Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to connect to development server? #5

Closed
perkola opened this issue May 31, 2016 · 1 comment
Closed

How to connect to development server? #5

perkola opened this issue May 31, 2016 · 1 comment

Comments

@perkola
Copy link
Contributor

perkola commented May 31, 2016

I'm following the example code and I've set up a Hub like so:

    public class Startup
    {
        public void Configuration(IAppBuilder app)
        {
            app.MapSignalR();
        }
    }

And my dev server can be reached from localhost:64726. However what do I replace in the following line?

var connection = signalr.hubConnection('http://<your-signalr-server-url>');

I have tried http://localhost:64726, http://10.0.2.2:64726 and more but all give the same result:

Error: Error during negotiation request.

Any ideas on how to connet my React Native App to SignalR?

Edit: trying to access http://10.0.2.2:64726 in the emulator browsers yields

Bad Request - Invalid Hostname

--------------------------------------------------------------------------------

HTTP Error 400. The request hostname is invalid.
@perkola
Copy link
Contributor Author

perkola commented Aug 4, 2016

Update: everything works. Had to use this tool to make it work.

Confirming this package works on Android (tested with RN 0.30.0.

@perkola perkola closed this as completed Aug 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant