From cf75417f229224fc05257ea6ddaa28a0f1a39d0f Mon Sep 17 00:00:00 2001 From: Vijay Dev Date: Mon, 5 Mar 2012 22:41:13 +0530 Subject: document the shortcut to the root route helper [ci skip] This was implemented in 2ee4dd856d47113625589bc5410b5a6669ea02d5 --- railties/guides/source/routing.textile | 1 + 1 file changed, 1 insertion(+) (limited to 'railties/guides/source') diff --git a/railties/guides/source/routing.textile b/railties/guides/source/routing.textile index 42665114be..c5567b3350 100644 --- a/railties/guides/source/routing.textile +++ b/railties/guides/source/routing.textile @@ -622,6 +622,7 @@ You can specify what Rails should route +"/"+ to with the +root+ method: root :to => 'pages#main' +root 'pages#main' # shortcut for the above You should put the +root+ route at the top of the file, because it is the most popular route and should be matched first. You also need to delete the +public/index.html+ file for the root route to take effect. -- cgit v1.2.3