Class: MdRecord::Loader

Inherits:
Object
  • Object
show all
Defined in:
lib/md_record/loader.rb

Instance Method Summary collapse

Constructor Details

#initialize(path:) ⇒ Loader

Returns a new instance of Loader.



5
6
7
# File 'lib/md_record/loader.rb', line 5

def initialize(path:)
  @path = Pathname.new(path).expand_path
end

Instance Method Details

#loadObject



9
10
11
# File 'lib/md_record/loader.rb', line 9

def load
  markdown_files.map { |file| yield file }
end