I want to do a conditional rendering at the layout level based on the actual template has defined content_for(:an__area)
, any idea how to get this done?
@content_for_whatever
is deprecated.
Use content_for?
instead, like this:
<% if content_for?(:whatever) %>
<div><%= yield(:whatever) %></div>
<% end %>