When your Rails application receives an incoming request
GET /projects/17
it asks the router to match it to a controller action. If the first matching route is
match "/projects/:id" => "projects#show"
the request is dispatched to the projects controller’s show action with { :id => “17” } in params.
Similarly, When your Rails application receives an incoming request
GET /projects/manage
it asks the router to match it to a controller action. If the first matching route is
match "/projects/manage" => "projects#manage", :as => 'manage_projects'
the request is dispatched to the projects controller’s manage action without bothering about the id as not given in routes.
But if the first matching route for projects is resource itself for projects, then it will go the show action as it will treat manage
as your id
just like having /projects/:id
and match will get skipped.
So it depends what have you given first i.e. a resource or a match. Priority is important.