Allow adding custom Macroable classes. (#1629)

* Allow adding custom Macroable classes.

* Remove duplication, tweak config

* Remove test

---------

Co-authored-by: Barry vd. Heuvel <[email protected]>
This commit is contained in:
Mathieu TUDISCO
2025-01-01 13:17:20 +01:00
committed by GitHub
co-authored by Barry vd. Heuvel
parent beda399e7e
commit 05d9c3cd65
5 changed files with 36 additions and 32 deletions
+2
View File
@@ -115,6 +115,8 @@ Str::macro('concat', function(string $str1, string $str2) : string {
});
```
You can add any custom Macroable traits to detect in the `macroable_traits` config option.
### Automatic PHPDocs for models
If you don't want to write your properties yourself, you can use the command `php artisan ide-helper:models` to generate