sframe / config
config component
dev-master
2014-12-04 13:44 UTC
Requires
- php: >=5.4.0
- illuminate/filesystem: 4.2.*
This package is not auto-updated.
Last update: 2024-12-31 05:47:35 UTC
README
A simple way to load array config in file.
Installation
composer require "sframe/config:dev-master"
Usage
config_path/test.php
return array( 'a' => 'aaa', 'b' => array( 'b1' => '111', 'b2' => '222' ) );
config_path/tt.php
return array( 'hello' => 'hhhhh' );
demo.php
$config = new SFrame\Config\FileArray('config_path'); $a = $config->get('test.a'); $b1 = $config->get('test.b.b1'); $hl = $config->get('tt.hello', 'default'); $is_exists = $config->has('test.d');