I’ve created the NuGet package “AspNetCore.RouteAnalyzer” that provides a feature to get all route information.
- NuGet Gallery | AspNetCore.RouteAnalyzer … Package on NuGet Gallery
- kobake/AspNetCore.RouteAnalyzer … Usage guide
Try it if you’d like.
Usage
Package Manager Console
PM> Install-Package AspNetCore.RouteAnalyzer
Startup.cs
using AspNetCore.RouteAnalyzer; // Add
.....
public void ConfigureServices(IServiceCollection services)
{
....
services.AddRouteAnalyzer(); // Add
}
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
....
app.UseMvc(routes =>
{
routes.MapRouteAnalyzer("/routes"); // Add
....
});
}
Browse
Run project and you can access the url /routes
to view all route information of your project.