Sha256: 87bc1c27fc58780a7f448d97a5df249bc900e02409223c56454792d7fab95d83

Contents?: true

Size: 361 Bytes

Versions: 19

Compression:

Stored size: 361 Bytes

Contents

# frozen_string_literal: true

module Luo
  module Helpers
    extend self

    def print_md(text)
      puts TTY::Markdown.parse(text)
    end

    def load_test(path, &block)
      data = YAML.load_file(path)
      if data.is_a?(Array)
        data.each do |value|
          yield(value)
        end
      else
        yield(data)
      end
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
luo-0.1.25 lib/luo/helpers.rb
luo-0.1.24 lib/luo/helpers.rb
luo-0.1.23 lib/luo/helpers.rb
luo-0.1.22 lib/luo/helpers.rb
luo-0.1.21 lib/luo/helpers.rb
luo-0.1.20 lib/luo/helpers.rb
luo-0.1.18 lib/luo/helpers.rb
luo-0.1.17 lib/luo/helpers.rb
luo-0.1.16 lib/luo/helpers.rb
luo-0.1.15 lib/luo/helpers.rb
luo-0.1.14 lib/luo/helpers.rb
luo-0.1.13 lib/luo/helpers.rb
luo-0.1.12 lib/luo/helpers.rb
luo-0.1.11 lib/luo/helpers.rb
luo-0.1.10 lib/luo/helpers.rb
luo-0.1.9 lib/luo/helpers.rb
luo-0.1.8 lib/luo/helpers.rb
luo-0.1.7 lib/luo/helpers.rb
luo-0.1.6 lib/luo/helpers.rb