Any samples for mvc6 with signalr?

2020-05-19 00:02发布

问题:

I have a full-working ASP.NET MVC application (.NET Core, ASP.NET MVC 6).

I would now like to add a signalr to my application. Any samples for MVC with signalr?

回答1:

The MusicStore sample on GitHub use signalR
and the BugTracker sample also
and you have a sample in the SignalR-Server repo
Or you can look at my sample on GitHub



回答2:

I don't believe there are any yet.

The next version of SignalR, version 3, is designed for ASP.NET Core, SignalR 2 doesn't support this. If you look on the ASP website https://www.asp.net/learn it doesn't mention that you can use SignalR with ASP.NET Core .

Since ASP.NET Core makes use of NodeJS rather then NuGet for client-side libraries, a Node module would probably be created for SignalR. Only time will tell what SingalR 3 will look like.

This is also a relevant question What is the development status of SignalR 3?