v0.16.0
Added
-
Support for custom config classes via
config_class:
option (#136 by @solnic)extend Dry::Configurable(config_class: MyConfig)
Your config class should inherit from
Dry::Configurable::Config
. -
Return
Dry::Core::Constants::Undefined
(instead of nil) as the value for non-configured settings via adefault_undefined: true
option (#141 by @timriley)extend Dry::Configurable(default_undefined: true)
You must opt into this feature via the
default_undefined: true
option. Non-configured setting values are stillnil
by default.
Fixed
Changed
-
Improve memory usage by separating setting definitions from config values (#138 by @timriley)
Your usage of dry-configurable may be impacted if you have been accessing objects from
_settings
or the internals ofDry::Configurable::Config
._settings
now returnsDry::Configurable::Setting
instances, which contain only the details from the setting's definition. Setting values remain inDry::Configurable::Config
.