Routes.rb

I’m following the tutorial here:
http://edgeguides.rubyonrails.org/getting_started.html

And, so far, I have the following in the routes.rb file:

get “home/index”
resources :posts
root :to => “home#index”

I know what "root :to => “home#index” is.

But, what is the use of the following, what do they mean?

get “home/index”
resources :posts

Thanks.

run

rake routes

and you’ll see all the routes they create. comment one out and run it
again to see what goes away

Tony P. wrote:

run

rake routes

and you’ll see all the routes they create. comment one out and run it
again to see what goes away

Thanks Tony.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs