Module: Locomotive::ActionController::SectionHelpers::ClassMethods
- Defined in:
- lib/locomotive/action_controller/section_helpers.rb
Instance Method Summary collapse
Instance Method Details
#sections(main, sub = nil) ⇒ Object
17 18 19 20 21 22 23 |
# File 'lib/locomotive/action_controller/section_helpers.rb', line 17 def sections(main, sub = nil) before_filter do |c| sub = sub.call(c) if sub.respond_to?(:call) sections = { :main => main, :sub => sub } c.instance_variable_set(:@locomotive_sections, sections) end end |