Skip to content

Commit

Permalink
Document the fact that apps can declare their own root routes
Browse files Browse the repository at this point in the history
  • Loading branch information
jagthedrummer committed Jan 29, 2025
1 parent a1cf710 commit d7e7fcf
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion config/routes.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Rails.application.routes.draw do

Check failure on line 2 in config/routes.rb

View workflow job for this annotation

GitHub Actions / 🔬 Standardrb / lint

Layout/EmptyLinesAroundBlockBody: Extra empty line detected at block body beginning.
# See `config/routes/*.rb` to customize these configurations.
draw "concerns"
draw "devise"
Expand All @@ -17,7 +18,9 @@

scope module: "public" do
# To keep things organized, we put non-authenticated controllers in the `Public::` namespace.
# The root `/` path is routed to `Public::HomeController#index` by default.
# The root `/` path is routed to `Public::HomeController#index` by default. You can set it
# to whatever you want by doing something like this:
# root to: "my_new_root_controller#index"
end

namespace :webhooks do
Expand All @@ -35,6 +38,10 @@

namespace :account do
shallow do
# The account root `/` path is routed to `Account::Dashboard#index` by default. You can set it
# to whatever you want by doing something like this:
# root to: "some_other_root_controller#index", as: "dashboard"

# user-level onboarding tasks.
namespace :onboarding do
# routes for standard onboarding steps are configured in the `bullet_train` gem, but you can add more here.
Expand Down

0 comments on commit d7e7fcf

Please sign in to comment.