Sha256: 6c513e9ea8528889eae50452477562ac5890ce32918ded5344ffa1480437b697
Contents?: true
Size: 576 Bytes
Versions: 8
Compression:
Stored size: 576 Bytes
Contents
# frozen_string_literal: true require 'dato/dump/format/toml' require 'dato/dump/format/yaml' module Dato module Dump module Format def self.dump(format, value) converter_for(format).dump(value) end def self.frontmatter_dump(format, value) converter_for(format).frontmatter_dump(value) end def self.converter_for(format) case format.to_sym when :toml Format::Toml when :yaml, :yml Format::Yaml when :json Format::Json end end end end end
Version data entries
8 entries across 8 versions & 1 rubygems