Skip to content

Latest commit

 

History

History
42 lines (29 loc) · 1.11 KB

ide-helper.md

File metadata and controls

42 lines (29 loc) · 1.11 KB

IDE-helper

Enumhancer is using a lot of magic. For the most basic functionality, enumhancer now comes with an IDE-helper. This is a separate package.

Installation

First, you need to install the IDE-helper package.

composer require --dev henzeb/enumhancer-ide-helper

Configure with dump-autoload

The IDE-helper out of the box supports the usage inside composer's post-autoload-dump event.

 "post-autoload-dump": [
"Henzeb\\Enumhancer\\Composer\\IdeHelper::generate"
]

Note: You can leave this line in your composer file. The IdeHelper class is part of the main library and executes enumhancer-ide-helper only if installed.

Configure as composer command

If you don't want to call dump-autoload everytime you need to generate the helper, it's possible to add it as a composer command.

"scripts": {
"enumhancer": "Henzeb\\Enumhancer\\Composer\\IdeHelper::generate"
}

Ignore IDE-helper generated files

The filename that is being generated by default is _enumhancer.php and is created inside the root of your project. Simply add the filename to your .ignore file.