I recently updated the Visual Studio for Update 3
and ASP.Net Core for 1.0.0.
I followed the tutorial in documentation and I tried set up for use Areas like this https://docs.asp.net/en/1.0.0/mvc/controllers/areas.html
However, the link generated was http://localhost:2187/?area=Admin, instead of http://localhost:2187/Admin/Home/Index
Update
My routes:
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller=Home}/{action=Index}/{id?}");
routes.MapRoute(
name: "areaRoute",
template: "{area}/{controller=Home}/{action=Index}");
});
What is wrong?
Solution
The problem was in the order of the routes as answer mentioned.