Skip to content

Instantly share code, notes, and snippets.

@tocalai
Created September 2, 2019 02:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tocalai/5e0ace63e3ebae5916252f115b1fca71 to your computer and use it in GitHub Desktop.
Save tocalai/5e0ace63e3ebae5916252f115b1fca71 to your computer and use it in GitHub Desktop.
Demonstrate Hub for signalR
using Microsoft.AspNetCore.SignalR;
using Microsoft.AspNetCore.SignalR;
namespace SignalR.Lab.Web.Hubs
{
public interface IEventHub
{
// here place some method(s) for message from server to client
Task SendNoticeEventToClient(string message);
}
public class EventHub : Hub<IEventHub>
{
// here place some method(s) for message from client to server
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment