soyhuce/service-provider-registrar

Load other service providers based on current environment

1.2.0 2022-01-06 14:25 UTC

This package is auto-updated.

Last update: 2022-01-07 12:06:51 UTC


README

Latest Version on Packagist Total Downloads

Objectives

This package allows to load other service providers based on current environment

Installation

You can install the package via composer:

composer require soyhuce/service-provider-registrar

Make a ServiceProvider which extend Soyhuce\ServiceProviderRegistrar\ServiceProvider :

namespace App\Providers;

use Soyhuce\ServiceProviderRegistrar\ServiceProvider;

class RegistrationServiceProvider extends ServiceProvider
{
    
}

Don't forget to add this ServiceProvider to your config/app.php file!

For each environment you wish, you have to define which service provider you want to use:

class RegistrationServiceProvider extends ServiceProvider
{
    public $local = [
        \Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class
    ];
}

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

License

The MIT License (MIT). Please see License File for more information.