andrey-helldar/laravel-ide-facades-helper

This package is abandoned and no longer maintained. The author suggests using the dragon-code/laravel-ide-facades-helper package instead.

Laravel IDE Facade Helper, generates correct PHPDocs for your Facade classes, to improve auto-completion.

v1.6.0 2021-10-31 18:14 UTC

This package is auto-updated.

Last update: 2021-11-16 13:15:14 UTC


README

Laravel IDE Facade Helper

Total Downloads Latest Stable Version Latest Unstable Version

StyleCI License

Laravel IDE Facade Helper, generates correct PHPDocs for your Facade classes, to improve auto-completion.

Note This package has been deprecated. Use the Laravel Idea plugin instead.

Installation

Require this package with composer using the following command:

$ composer require dragon-code/laravel-ide-facades-helper --dev

This package makes use of Laravels package auto-discovery mechanism, which means if you don't install dev dependencies in production, it also won't be loaded.

If for some reason you want manually control this:

  • add the package to the extra.laravel.dont-discover key in composer.json, e.g.
    "extra": {
      "laravel": {
        "dont-discover": [
          "dragon-code/laravel-ide-facades-helper",
        ]
      }
    }
  • Add the following class to the providers array in config/app.php:
    DragonCode\LaravelIdeFacadesHelper\ServiceProvider::class,
    If you want to manually load it only in non-production environments, instead you can add this to your AppServiceProvider with the register() method:
    public function register()
    {
        if ($this->app->environment() !== 'production') {
            $this->app->register(\DragonCode\LaravelIdeFacadesHelper\ServiceProvider::class);
        }
        // ...
    }

Note: Avoid caching the configuration in your development environment, it may cause issues after installing this package; respectively clear the cache beforehand via php artisan cache:clear if you encounter problems when running the commands

Usage

  • php artisan ide-helper:facades - PHPDoc generation for your Facades

You can generate helpers for your facades.

You will find additional settings in the options facade_locations and facades_visibility of the config/ide-helper.php file.

Note: The package uses the same file as barryvdh/laravel-ide-helper. Therefore, if you need to redefine the paths, add the configuration from this file to it.

License

This package is licensed under the MIT License.