Hi everyone.
How to ignore route in ASP.NET vNext (MVC 6)?
Now I using the following routing config:
public void Configure(IApplicationBuilder app)
{
app.UseMvc();
app.UseMvc(routes =>
{
routes.MapRoute(
"Root",
"{*url}",
new { controller = "Root", action = "Root"}
);
});
}
The global root controller render a view in which I initialize AngularJS. It works for me, but I need to ignore routes for .css | .js | .*images_extensions* .
As I understood the following code doesn't work for this version of ASP.NET vNext:
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
How I can make ignoring of a route?
Thanks in advance.