Sha256: 5623d9a769d3cdde5bfb6bf30d6e131fb36f9bf0a6679b2d5b987dcf14072a3f
Contents?: true
Size: 1.29 KB
Versions: 4
Compression:
Stored size: 1.29 KB
Contents
[gitter]: https://gitter.im/dry-rb/chat [gem]: https://rubygems.org/gems/dry-configurable [travis]: https://travis-ci.org/dry-rb/dry-configurable [code_climate]: https://codeclimate.com/github/dry-rb/dry-configurable [inch]: http://inch-ci.org/github/dry-rb/dry-configurable # dry-configurable [![Join the Gitter chat](https://badges.gitter.im/Join%20Chat.svg)][gitter] [![Gem Version](https://img.shields.io/gem/v/dry-configurable.svg)][gem] [![Build Status](https://img.shields.io/travis/dry-rb/dry-configurable.svg)][travis] [![Code Climate](https://img.shields.io/codeclimate/github/dry-rb/dry-configurable.svg)][code_climate] [![Test Coverage](https://img.shields.io/codeclimate/coverage/github/dry-rb/dry-configurable.svg)][code_climate] [![API Documentation Coverage](http://inch-ci.org/github/dry-rb/dry-configurable.svg)][inch] ## Synopsis ```ruby class App extend Dry::Configurable # Pass a block for nested configuration (works to any depth) setting :database do # Can pass a default value setting :dsn, 'sqlite:memory' end # Defaults to nil if no default value is given setting :adapter end App.configure do |config| config.database.dsn = 'jdbc:sqlite:memory' end App.config.database.dsn # => 'jdbc:sqlite:memory' App.config.adapter # => nil ``` ## License See `LICENSE` file.
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
dry-configurable-0.5.0 | README.md |
dry-configurable-0.4.0 | README.md |
dry-configurable-0.3.0 | README.md |
dry-configurable-0.1.7 | README.md |