class Bridgetown::Utils::RubyFrontMatter
Public Class Methods
new()
click to toggle source
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 12 def initialize @data = {} end
Public Instance Methods
each(&block)
click to toggle source
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 22 def each(&block) @data.each(&block) end
get(key)
click to toggle source
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 26 def get(key) @data[key] end
method_missing(key, value)
click to toggle source
Calls superclass method
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 16 def method_missing(key, value) # rubocop:disable Style/MissingRespondToMissing return super if respond_to?(key) set(key, value) end
set(key, value)
click to toggle source
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 30 def set(key, value) @data[key] = value end
to_h()
click to toggle source
# File lib/bridgetown-core/utils/ruby_front_matter.rb, line 34 def to_h @data end