Razor Pages Ignore Routing

Viewed 82

I use Conventions to declare routes in ASP.NET Core 3 like below:

.AddRazorPagesOptions(options => {
    options.Conventions.AddPageRoute("/forms", "{lang}/forms");
}

How I can EXCLUDE a path from routing? ex. Javascript and Images folder like what we did in ASP as routes.Ignore("{file}.js");

I spent hours googling but nothing!

0 Answers
Related