Please sign in to comment.
Only display the sidebar if it has some content
If we don't have content_for :index_items, then we can assume, we are not on a guide page (e.g. we are on Credits we don't need a Chapters sidebar). In addition to this, we let each page to provide content_for :sidebar in case there is a need to provide custom content (e.g. in the index page, have some special items on the sidebar). If we don't have content_for either :index_items or :sidebar, we hide the sidebar.
- Loading branch information...
Showing with 9 additions and 1 deletion.