Class: Smithy::Site

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
app/models/smithy/site.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.titleObject



7
8
9
# File 'app/models/smithy/site.rb', line 7

def title
  @@title
end

.title=(str) ⇒ Object



11
12
13
# File 'app/models/smithy/site.rb', line 11

def title=(str)
  @@title = str
end

Instance Method Details

#rootObject



20
21
22
# File 'app/models/smithy/site.rb', line 20

def root
  @root ||= Smithy::Page.root
end

#titleObject



16
17
18
# File 'app/models/smithy/site.rb', line 16

def title
  self.class.title
end

#to_liquidObject



24
25
26
27
28
29
# File 'app/models/smithy/site.rb', line 24

def to_liquid
  {
    'title' => self.title,
    'root' => self.root.to_liquid
  }
end