Class: Super::Layout

Inherits:
Object
  • Object
show all
Includes:
Partial::Resolving
Defined in:
lib/super/layout.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Partial::Resolving

resolve_for_rendering

Constructor Details

#initialize(header: nil, aside: nil, main: nil, footer: nil) ⇒ Layout

Returns a new instance of Layout.



9
10
11
12
13
14
# File 'lib/super/layout.rb', line 9

def initialize(header: nil, aside: nil, main: nil, footer: nil)
  @header = header
  @aside = aside
  @main = main
  @footer = footer
end

Instance Attribute Details

#asideObject (readonly)

Returns the value of attribute aside.



17
18
19
# File 'lib/super/layout.rb', line 17

def aside
  @aside
end

Returns the value of attribute footer.



19
20
21
# File 'lib/super/layout.rb', line 19

def footer
  @footer
end

#headerObject (readonly)

Returns the value of attribute header.



16
17
18
# File 'lib/super/layout.rb', line 16

def header
  @header
end

#mainObject (readonly)

Returns the value of attribute main.



18
19
20
# File 'lib/super/layout.rb', line 18

def main
  @main
end

Instance Method Details

#to_partial_pathObject



21
22
23
# File 'lib/super/layout.rb', line 21

def to_partial_path
  "layout"
end