Routing to Controller Actions
ASP.NET MVC -> Controllers -> Routing to Controller Actions
- Relationship to middleware (#61)
- Startup code and relationship to MVC route handler
- Attribute routing
[Route],[Http*]- Routes on controller vs actions
- Inheritance
- Token replacement in route templates (
[controller],[action],[area]) - Custom route attributes using
IRouteTemplateProvider - Pointer to using Application Model to customize attribute routes
- Conventional routing
- Mapping of action/area/controller maps to a controller action (action selection)
- Action constraints
- HTTP method constraints
- Custom constraints
cc @ssargent
Is there going to be any way to create route configuration files that point directly to controllers? There still seems to be quite a heavy focus on attribute routing. This ticket explains some of the things I'd hope to see made available.
Some existing content we might leverage: http://www.asp.net/web-api/overview/web-api-routing-and-actions/attribute-routing-in-web-api-2
@danroth27 - I meant, not using attribute routing. "route configuration files that point directly to controllers".
Attribute and in-code routes are a somewhat dated practice compared to what other mature frameworks out there are doing.
This is about documenting the existing features. Use that ticket to further ask for things (or open a new one) but this issue isn't about adding new features.
o_O
Initial content in PR: https://github.com/aspnet/Docs/pull/602
Any way to map routes in a separate file / class? @danroth27 @atrauzzi
I have searched everywhere for some content on how to handle custom inline route constraints in MVC 6. Are they still in?
When you say custom, you mean beyond the ones that are available here?
https://github.com/aspnet/Routing/blob/1.0.0-rc1/src/Microsoft.AspNet.Routing/RouteOptions.cs
Any updates on this issue? I would appreciate some documentation on this topic :) ... would older documentation work until then?
It's in progress
I'd be happy to be a test-subject for your documentation when you feel it's ready. I'm about 200 hours into working with MVC/webapi after about 25 years of software engineering experience. [email protected].
fixed by https://docs.asp.net/en/latest/mvc/controllers/routing.html