When I start my ASP.NET MVC application up, it does not hit the HomeController
's Index
action, but when I explicitly type the URL Home/Index
, it works as expected.
Here is how the end point is set up in Startup.cs
:
app.UseEndpoints(endpoints =>
{
// endpoints.MapControllers();
endpoints.MapControllerRoute("default", "{controller=Home}/{action=Index}/{id?}");
// Blazor
endpoints.MapFallbackToPage("/_Host");
endpoints.MapBlazorHub();
});