From 035b14176bd25826bb55135cd9e2b8b476788f1f Mon Sep 17 00:00:00 2001 From: Chris Forrence Date: Fri, 12 Aug 2016 17:39:45 -0400 Subject: [PATCH] Add instructions on installing for development --- readme.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/readme.md b/readme.md index f926309..06a3825 100644 --- a/readme.md +++ b/readme.md @@ -38,6 +38,24 @@ After updating composer, add the service provider to the `providers` array in `c Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class, ``` +To install this package on only development systems, add the `--dev` flag to your composer command: + +```bash +composer require --dev barryvdh/laravel-ide-helper +``` + +Instead of adding the service provider in the `config/app.php` file, add the following code to your `app/Providers/AppServiceProvider.php` file, within the `register()` method: + +```php +public function register() +{ + if($this->app->environment() !== 'production') { + $this->app->register(\Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class); + } + // ... +} +``` + ### Automatic phpDoc generation for Laravel Facades