Benito Serna
Trying to build software that works

User-centric Routing with Devise and Rails

Maybe there is a lot of people know this solution, but before today I didn’t know it, so I want to share this =).

Imagine that you want that the home page of your app for an authenticated user, to be a Dashboard with stadistics or something special, but you want to have an informative page for the people that is not authenticated.

With Devise you can solve this problem beautifully =)

authenticated do
  root :to => 'users#home'
end

root :to => 'pages#home'

Do you need some help with TDD?

I have an email course with with a guide to help you start with TDD!


Do you want to know more?