Strongly Typed Middleware in ASP.NET Core

added by DotNetKicks
8/25/2022 4:10:14 PM

238 Views

First, let's remind ourselves how conventions-based middleware works. The two conventions that must be applied to a conventions-based middleware class are to declare a constructor that takes a RequestDelegate as a parameter representing the next middleware in the pipeline, and a method named Invoke or InvokeAsync that returns a Task and has at least one parameter, the first being an HttpContext.


0 comments