Add YAML file support to Laravel Configuration
krom/laravel-yaml-configuration is a Laravel package for add yaml file support to laravel configuration.
It currently has 0 GitHub stars and 3 downloads on Packagist (latest version 2.1.2).
Install it with composer require krom/laravel-yaml-configuration.
Discover more Laravel packages by krom
or browse all Laravel packages to compare alternatives.
Last updated
This package uses Symfony/Yaml parser.
Add "krom/laravel-yaml-configuration": "2.*" to your composer.json by running :
php composer.phar require krom/laravel-yaml-configuration
And select version : 2.*
You have to add (or merge)
protected function bootstrappers()
{
return array_merge($this->bootstrappers, [\\krom\\Core\\Config\\LoadYamlConfiguration::class]);
}
to your app/Http/Kernel.php and/or app/Console/Kernel.php.
Just use regular php files or use yml or yaml files instead.
PHP :
<?php
return [
'debug' => false,
'key' => 'foobar',
];
Will be equivalent to :
YAML
debug: false
key: foobar
You can use any php functions like that :
routes_file: %app_path%/routes.php
unit_test: %base_path:behat.yml%
something: %sprintf:hell %s,world%
Enjoy it ! Feel free to fork :) !
This package is fork of devitek/yaml-configuration