enjoys / config
Parse config files
Installs: 2 022
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: ^7.4|^8.0
- ext-json: *
- enjoys/functions: ^2.3
- psr/log: ^1.0 | ^2.0 | ^3.0
- symfony/yaml: ^5.4|^6.0
Requires (Dev)
- php-coveralls/php-coveralls: ^2.4
- phpunit/phpunit: ^9.4
- squizlabs/php_codesniffer: 3.*
- vimeo/psalm: ^4.1
README
Install
composer require enjoys/config
Usage
$config = new Enjoys\Config\Config(); $config->addConfig($configFilepath1); $config->addConfig($configFilepath2, [], \Enjoys\Config\Config::YAML); $config->get('key', 'defaultValue'); //get from $array['key'] $config->get('key->subKey'); //get from $array['key']'subKey']