I’m using layout to make all actions to render :main layout:
class Pages < E
layout :main
# actions that using layout
# pager should not use layout
def pager
end
end
How to exclude pager from the list of actions that using layout?
I understand i can use this:
setup :action_1, :action_2 do
layout :main
end
But when i have lot of actions it becomes hairy.
You should set layout to
falseto disable it.For your case use this:
Perhaps not really intuitive but it is done like this to avoid redundant options like
exclude,except,onlyetc.You also can skip setup and use
render_partial: