bsfp/config

framework

Maintainers

Details

github.com/bsfp/config

Source

Issues

Installs: 8

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 1

Forks: 2

Open Issues: 0

pkg:composer/bsfp/config

dev-master 2018-11-11 23:54 UTC

This package is auto-updated.

Last update: 2025-09-12 14:43:44 UTC


README

API

Configuration

new \BSFP\C(__DIR__ . '/path/to/configFolder');

Retrieve your config

\BSFP\C::get('filename');

Work with one level of folder and Yaml and Json files.

Demo

config/hello.json

{
  "what": "world"
}

index.php

<?php

new \BSFP\C(__DIR__ . '/config');

echo 'Hello ' . \BSFP\C::get('hello')->get('what');

result:

php index.php

Hello world

Run tests

./vendor/bin/phpunit --bootstrap vendor/autoload.php tests