|
|
|
|
|
by michielr
1113 days ago
|
|
I agree this was a problem, but with the current Minimal API's, there is no boilerplate, looks a lot like Express to me! var builder = WebApplication.CreateBuilder(args);
var app = builder.Build();
app.MapGet("/", () => "Hello World!");
app.Run();
|
|
Your code snippet certainly has a lot of unnecessary ceremony. Why use a builder object at all? Why use a static class with a function to build the builder object?
Would be better. But Is even better. No ceremony at all!