I am working on creating an app using Devise and Pundit to create users and assign them roles.
With that, I want to have role-based views in my app. I'm having a hard time thinking through how to make that possible.
When you login, if you're a user
you should redirect to the user
home view. If you're a manager
you should redirect to a manager
home view.
What's the best way, at a high level, to write that logic? Should it live in a controller, a view, perhaps utilize partials to keep things DRY....
Any tips are appreciated.