Skip to content

Instantly share code, notes, and snippets.

@jlebrech
Created February 25, 2013 10:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jlebrech/5029023 to your computer and use it in GitHub Desktop.
Save jlebrech/5029023 to your computer and use it in GitHub Desktop.
how to send "/:username" to "show/username" and nest favourites into "/username"
...
resources :users do # should map "/:username" to user_controller/show
resources :favourites do # should send /:username/favourites, to favourite_controller/index
resources :fruit, :cars, :sports, :foods
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment