Skip to content

Commit b8c6b7e

Browse files
mfnnetpok
authored andcommitted
Update README to promote the post_discover hook
1 parent bf77559 commit b8c6b7e

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

README.md

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,16 +87,13 @@ Note: `bootstrap/compiled.php` has to be cleared first, so run `php artisan clea
8787

8888
This will generate the file `_ide_helper.php` which is expected to be additionally parsed by your IDE for autocomplete. You can use the config `filename` to change its name.
8989

90-
You can configure your `composer.json` to do this each time you update your dependencies:
91-
92-
```js
93-
"scripts": {
94-
"post-update-cmd": [
95-
"Illuminate\\Foundation\\ComposerScripts::postUpdate",
96-
"@php artisan ide-helper:generate",
97-
"@php artisan ide-helper:meta"
98-
]
99-
},
90+
You can use the `post_discover` config to run any artisan commands after installing/update packages:
91+
92+
```php
93+
'post_discover' => [
94+
'ide-helper:generate',
95+
'ide-helper:meta',
96+
],
10097
```
10198

10299
You can also publish the config file to change implementations (ie. interface to specific class) or set defaults for `--helpers`.

0 commit comments

Comments
 (0)