Skip to content

Commit

Permalink
routes
Browse files Browse the repository at this point in the history
  • Loading branch information
adnjoo committed Oct 19, 2024
1 parent 3b715fb commit 0fafb02
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions config/routes.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,19 @@
Rails.application.routes.draw do
devise_for :users
resources :notes, except: [ :show ]

devise_scope :user do
authenticated :user do
root to: "notes#index", as: :authenticated_root
end

unauthenticated do
root to: "pages#home"
end
end

resources :notes, except: [ :show, :index ]

# Static Pages
root to: "pages#home"
get "about", to: "pages#about", as: :about

# API namespace for isolated routes
Expand Down

0 comments on commit 0fafb02

Please sign in to comment.