2017 © Pedro Peláez
 

library laravel-feature-switches

Allows you to configure feature switches

image

ronaldvaneede/laravel-feature-switches

Allows you to configure feature switches

  • Tuesday, August 13, 2013
  • by ronaldvaneede
  • Repository
  • 1 Watchers
  • 20 Stars
  • 14 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Feature switches in Laravel 4

Latest Stable Version Total Downloads Build Status, (*1)

This package allows you to use feature switches in your code., (*2)

Installation

You can install this package trough Composer. Add this to your composer.json file:, (*3)

"require": {
    // ...
    "ronaldvaneede/laravel-feature-switches": "dev-master"
}

Now run composer install or composer update to download it., (*4)

After that add the service provider to the providers array within the app/config/app.php file., (*5)

'providers' => array(
    // ...
    'Ronaldvaneede\Featureswitch\FeatureswitchServiceProvider',
)

That's it!, (*6)

Using Feature switches

To use the feature switches you have to add this to the app/config/app.php file:, (*7)

'features' => array(
    'feature-a' => array('enabled' => 'on'),
    'feature-b' => array('enabled' => 'off')
)

Then you can use Featureswitch::allow('feature-a') and Featureswitch::allow('feature-b') to check if the feature is available. The allow() method will return either true or false., (*8)

Wishes

In the end this should support a configuration like this:, (*9)

// on / off / users -> user_list => 'a,b,c' / staff / 1%
'features' => array(
    'login' => array('enabled' => 'on'),
    'facebook' => array('enabled' => 'off'),
    'google+' => array('enabled' => '5%'),
    'twitter' => array('enabled' => 'users', 'user_list' => 'ronald,jaap,piet')
)

The Versions

13/08 2013

dev-master

9999999-dev http://github.com/ronaldvaneede/laravel-feature-switches

Allows you to configure feature switches

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel laravel 4 laravel4 feature switch featureswitches featureswitch feature switches

13/08 2013

v0.1.0

0.1.0.0 http://github.com/ronaldvaneede/laravel-feature-switches

Allows you to configure feature switches

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel laravel 4 laravel4 feature switch featureswitches featureswitch feature switches