Module: Erbside::MetadataMixin

Included in:
Erbside
Defined in:
lib/erbside.rb

Instance Method Summary collapse

Instance Method Details

#const_missing(name) ⇒ Object



12
13
14
15
# File 'lib/erbside.rb', line 12

def const_missing(name)
  key = name.to_s.downcase
  .key?(key) ? [key] : super(name)
end

#metadataObject



6
7
8
9
10
11
# File 'lib/erbside.rb', line 6

def 
  @_metadata ||= (
    require 'yaml'
    YAML.load_file(File.dirname(__FILE__) + '/erbside.yml')
  )
end