Last active
February 7, 2024 06:29
-
-
Save gistlyn/63520f8f50160dc924444e4c10248a95 to your computer and use it in GitHub Desktop.
Configure Server Events (SSE)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using ServiceStack; | |
[assembly: HostingStartup(typeof(MyApp.ConfigureServerEvents))] | |
namespace MyApp; | |
public class ConfigureServerEvents : IHostingStartup | |
{ | |
public void Configure(IWebHostBuilder builder) => builder | |
.ConfigureServices(services => { | |
services.AddPlugin(new ServerEventsFeature()); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment