For example in one of our API's we have multiple signalR hubs such as UserHub, DataHub, and Message Hub. In C# we would do something like:
var signalRConnection = new HubConnection("http://{serverUrl}"); var signalRUserProxy = signalRConnection.CreateHubProxy("UserHub"); var signalRDataProxy = signalRConnection.CreateHubProxy("DataHub"); var signalRMessageProxy = signalRConnection.CreateHubProxy("MessageHub"); signalRConnection.Start().Wait(); signalRUserProxy.On("updateUsers", x => UpdateUsers(x)); signalRDataProxy.On("updateData", x => UpdateData(x)); signalRMessageProxy.On("updateMessages", x => UpdateMessages(x));
Where each proxy represents a different Hub. I don't see how to accomplish this with the example code supplied.
For example in one of our API's we have multiple signalR hubs such as UserHub, DataHub, and Message Hub. In C# we would do something like:
var signalRConnection = new HubConnection("http://{serverUrl}"); var signalRUserProxy = signalRConnection.CreateHubProxy("UserHub"); var signalRDataProxy = signalRConnection.CreateHubProxy("DataHub"); var signalRMessageProxy = signalRConnection.CreateHubProxy("MessageHub"); signalRConnection.Start().Wait(); signalRUserProxy.On("updateUsers", x => UpdateUsers(x)); signalRDataProxy.On("updateData", x => UpdateData(x)); signalRMessageProxy.On("updateMessages", x => UpdateMessages(x));
Where each proxy represents a different Hub. I don't see how to accomplish this with the example code supplied.