benrowe/laravel-config
Larablocks Analysis
benrowe/laravel-config works with Laravel 5 (latest release v0.2, Jun 10, 2016), which reached end of life: no more fixes, even for security.
Recommendation checks
Not advisedNot advised: no release or commit in over 2 years.
- No release or commit in over 2 years
- Supports only Laravel 5, past end of life
- No release in the last 12 months (last: Jun 10, 2016)
- 0 downloads a month (needs 10,000)
- 1 GitHub star (needs 100)
State
Likely abandoned- No release or commit in over 2 years.
- Last stable release: Jun 10, 2016.
- No releases in the last 12 months.
- First released: May 12, 2016.
- 1 open issue on GitHub.
Data from Packagist and GitHub, checked by Larablocks on Dec 3, 2026.
| Install | |
|---|---|
composer require benrowe/laravel-config |
|
| Latest Version: | v0.2 |
| Laravel: | 5 |
| License: | MIT |
| Last Updated: | Jun 11, 2016 |
| Links: | GitHub · Packagist |
Laravel Config
A Laravel runtime configuration handler that supports hierarchical configuration, however when stored, the data is flattened to basic key/value pairs (this allows for more possible storage options)
<?php
use Benrowe\Laravel\Config\Config;
$config = new Config([
'foo.bar[0]' => 'Hello',
'foo.bar[1]' => 'World',
'foo.key' => 'Value'
]);
$foo = $config->get('foo'); // => ['bar' => ['Hello', 'World'], 'key' => 'Value']
$bar = $config->get('foo.bar'); // => ['Hello', 'World']
Features
- Ability to store the configuration data into any persistent data store (file, db, etc).
- Provided Storage Adapters include Db, File, Redis.
- Dot notation syntax for configuration hierarchy.
- Values can be simple strings, or arrays of strings.
- Modifier support. Modifers can be registered to manipulate the value at runtime. (aka storing json, datetimes, booleans, etc).
- ServiceProvider included to configure the component based on the supplied configuration
- Facade support
Installation
Install the library using composer. Add the following to your composer.json:
{
"require": {
"benrowe/laravel-config": "0.1.*"
}
}
Now run the install command.
$ composer.phar install
This will provide access to the component via PSR-4. To configure the package as a laravel service, the service provider must be registered with the provided ServiceProvider.
Configuring Laravel
Once the package has been installed via composer, you need to register the service provider. To do this, edit your config/app.php and add a new option under the providers key.
Benrowe\Laravel\Config\ServiceProvider::class
Additionally you can register the provided facade.
'RuntimeConfig' => Benrowe\Laravel\Config\Facdes\Config::class,
With the service provider registered, this will give access to the config component, however it is not configured to persist any changes you make to the config. To do this, you need to publish the provided config file.
php artisan vendor:publish --provider="Benrowe\Laravel\Config\ServiceProvider" --tag="config"
This will publish a config.php file into your config directory. At this point you will need to edit the file and setup how you want to persist your configuration.
Additionally if you plan to store your configuration in a database (such as mysql, etc) you will need to publish the migration which stores the config schema
php artisan vendor:publish --provider="Benrowe\Laravel\Config\ServiceProvider" --tag="migrations"
Alternatives to benrowe/laravel-config
Guarantee database stickiness over the same user's consecutive requests
Version History
| Version | Released | Laravel | License |
|---|---|---|---|
| v0.2 | ^5.2 | MIT | |
| v0.1.1 | ^5.2 | MIT | |
| v0.1 | ^5.2 | MIT |
