diff options
author | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2014-01-14 02:13:28 -0800 |
---|---|---|
committer | Carlos Antonio da Silva <carlosantoniodasilva@gmail.com> | 2014-01-14 02:13:28 -0800 |
commit | 028029c1b622f326f254f09e76d2b618f578cd79 (patch) | |
tree | 9ca75d87fc871ce30654c0ba8cad2a0f0851c796 /guides | |
parent | c2a6fc42d2bed0558f74d61dab72e6eceea3f57c (diff) | |
parent | 9cdc7c0614fabc56d8560deeffae7e949bb9f464 (diff) | |
download | rails-028029c1b622f326f254f09e76d2b618f578cd79.tar.gz rails-028029c1b622f326f254f09e76d2b618f578cd79.tar.bz2 rails-028029c1b622f326f254f09e76d2b618f578cd79.zip |
Merge pull request #13705 from mess110/controller_generator_route_quotes
Single quotes for controller generated routes. This is more consistent with all other Rails generated code.
Diffstat (limited to 'guides')
-rw-r--r-- | guides/source/getting_started.md | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/guides/source/getting_started.md b/guides/source/getting_started.md index ebc56cba58..dbcedba800 100644 --- a/guides/source/getting_started.md +++ b/guides/source/getting_started.md @@ -231,7 +231,7 @@ Rails will create several files and a route for you. ```bash create app/controllers/welcome_controller.rb - route get "welcome/index" + route get 'welcome/index' invoke erb create app/views/welcome create app/views/welcome/index.html.erb @@ -272,13 +272,13 @@ Open the file `config/routes.rb` in your editor. ```ruby Rails.application.routes.draw do - get "welcome/index" + get 'welcome/index' # The priority is based upon order of creation: # first created -> highest priority. # # You can have the root of your site routed with "root" - # root "welcome#index" + # root 'welcome#index' # # ... ``` @@ -295,7 +295,7 @@ root 'welcome#index' ``` `root 'welcome#index'` tells Rails to map requests to the root of the -application to the welcome controller's index action and `get "welcome/index"` +application to the welcome controller's index action and `get 'welcome/index'` tells Rails to map requests to <http://localhost:3000/welcome/index> to the welcome controller's index action. This was created earlier when you ran the controller generator (`rails generate controller welcome index`). @@ -328,7 +328,7 @@ Blog::Application.routes.draw do resources :posts - root "welcome#index" + root 'welcome#index' end ``` |