From 5e7d6bba79393de0279917f93b82f3b7b176f4b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Fri, 29 Jun 2012 17:39:50 +0200 Subject: Revert "Allow loading external route files from the router" This reverts commit 6acebb38bc0637bc05c19d87f8767f16ce79189b. Usage of this feature did not reveal any improvement in existing apps. Conflicts: actionpack/lib/action_dispatch/routing/mapper.rb guides/source/routing.textile railties/lib/rails/engine.rb railties/lib/rails/paths.rb railties/test/paths_test.rb --- guides/source/routing.textile | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'guides/source') diff --git a/guides/source/routing.textile b/guides/source/routing.textile index dae25853cd..4de76ff100 100644 --- a/guides/source/routing.textile +++ b/guides/source/routing.textile @@ -845,24 +845,6 @@ end This will create routing helpers such as +magazine_periodical_ads_url+ and +edit_magazine_periodical_ad_path+. -h3. Breaking Up a Large Route File - -If you have a large route file that you would like to break up into multiple files, you can use the +#draw+ method in your router: - - -draw :admin - - -Then, create a file called +config/routes/admin.rb+. Name the file the same as the symbol passed to the +draw+ method. You can then use the normal routing DSL inside that file: - - -# in config/routes/admin.rb - -namespace :admin do - resources :posts -end - - h3. Inspecting and Testing Routes Rails offers facilities for inspecting and testing your routes. -- cgit v1.2.3