I do not know how best to do this.
On my application.html.erb, I define a div header.
My default controller (root) is the home controller. And I wish that if I am in the index of the main page, the heading is a rendering with some content, but all other controllers display different content inside this heading.
How can I create a condition in this div header to render various content based on the displayed controller?
source
share