Sha256: de21e0f68e140b7af6da94a16599bdb5da90eda488612d95587d972d64b3314a

Contents?: true

Size: 624 Bytes

Versions: 33

Compression:

Stored size: 624 Bytes

Contents

# frozen_string_literal: true

require "active_support/core_ext/hash/indifferent_access"

module Anyway
  module Rails
    # Enhance config to be more Railsy-like:
    # – accept hashes with indeferent access
    # - load data from secrets
    # - recognize Rails env when loading from YML
    module Config
      module ClassMethods
        # Make defaults to be a Hash with indifferent access
        def new_empty_config
          {}.with_indifferent_access
        end
      end
    end
  end
end

Anyway::Config.prepend Anyway::Rails::Config
Anyway::Config.singleton_class.prepend Anyway::Rails::Config::ClassMethods

Version data entries

33 entries across 33 versions & 2 rubygems

Version Path
anyway_config-2.6.4 lib/anyway/rails/config.rb
anyway_config-2.6.3 lib/anyway/rails/config.rb
anyway_config-2.6.2 lib/anyway/rails/config.rb
anyway_config-2.6.1 lib/anyway/rails/config.rb
anyway_config-2.6.0 lib/anyway/rails/config.rb
runger_config-3.0.1 lib/anyway/rails/config.rb
runger_config-3.0.0 lib/anyway/rails/config.rb
runger_config-2.7.0 lib/anyway/rails/config.rb
runger_config-2.6.1 lib/anyway/rails/config.rb
runger_config-2.6.0 lib/anyway/rails/config.rb
anyway_config-2.5.4 lib/anyway/rails/config.rb
anyway_config-2.5.3 lib/anyway/rails/config.rb
anyway_config-2.5.2 lib/anyway/rails/config.rb
anyway_config-2.5.1 lib/anyway/rails/config.rb
anyway_config-2.5.0 lib/anyway/rails/config.rb
anyway_config-2.4.2 lib/anyway/rails/config.rb
anyway_config-2.4.1 lib/anyway/rails/config.rb
anyway_config-2.4.0 lib/anyway/rails/config.rb
anyway_config-2.3.1 lib/anyway/rails/config.rb
anyway_config-2.3.0 lib/anyway/rails/config.rb