method

generate_routing_code

Importance_1
v6.0.0 - Show latest stable - 0 notes - Class: Rails::Generators::ControllerGenerator
generate_routing_code() private

This method creates nested route entry for namespaced resources. For eg. rails g controller foo/bar/baz index show Will generate - namespace :foo do

namespace :bar do
  get 'baz/index'
  get 'baz/show'
end

end

Show source
Register or log in to add new notes.