Sha256: 33cb755f8d338ad368c3dcb2e5803cf673e862c07ec2cc59f3d22038882bda43
Contents?: true
Size: 549 Bytes
Versions: 6
Compression:
Stored size: 549 Bytes
Contents
# frozen_string_literal: true require 'json' module I18n::Tasks module Data module Adapter module JsonAdapter class << self # @return [Hash] locale tree def parse(str, opts) JSON.parse(str, parse_opts(opts)) end # @return [String] def dump(tree, opts) JSON.generate(tree, parse_opts(opts)) end private def parse_opts(opts) opts.try(:symbolize_keys) || {} end end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems