Nested resource

At: http://edgeguides.rubyonrails.org/getting_started.html

Under: 7.3 Adding a Route for Comments

For the following:

resources :posts do
resources :comments
end

It says:

This creates comments as a nested resource within posts. This is another
part of capturing the hierarchical relationship that exists between
posts and comments.

Does this mean that we made resources :comments nested in resources
:posts based on the model relationship?

What is we just listed resources :comments without nesting?

Thanks.

Does this mean that we made resources :comments nested in resources
:posts based on the model relationship?

yes

Please read section 2.7 of
http://edgeguides.rubyonrails.org/routing.html

Sijo

Sijo k g wrote:

Does this mean that we made resources :comments nested in resources
:posts based on the model relationship?

yes

Please read section 2.7 of
http://edgeguides.rubyonrails.org/routing.html

Sijo

Thanks Sijo.