add signalr support
This commit is contained in:
@ -1,9 +1,11 @@
|
||||
using BinaryDad.Notes;
|
||||
using BinaryDad.Notes.Services;
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
// Add services to the container.
|
||||
builder.Services.AddControllersWithViews();
|
||||
builder.Services.AddSignalR();
|
||||
builder.Services.AddSingleton<INoteService, FileNoteService>();
|
||||
|
||||
var app = builder.Build();
|
||||
@ -24,4 +26,6 @@ app.MapControllerRoute(
|
||||
name: "default",
|
||||
pattern: "{controller=Home}/{action=Index}/{id?}");
|
||||
|
||||
app.MapHub<NoteHub>("/noteHub");
|
||||
|
||||
app.Run();
|
||||
|
Reference in New Issue
Block a user