-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missing Class-level PHPDoc when using Laravel IDE Helper for models #1666
Comments
Yes, was removed a year ago in #1523 |
Maybe to add: if you had it from before, after that change, it was treated like any additional text and was preserved. So for those who upgraded all along, they might never noticed that it was removed until they e.g. manually remove the whole phpdoc or start a new project. |
Depending on the IDE settings, spaces at the end of lines may be removed when saving, so if we open a class and edit it, then cancel the changes and save, the space will be removed and the class will be changed. We will commit unnecessary changes. Then we will run IDE Helper and the space will be added again, and again unnecessary changes. |
Seems like a separate issue, PRs welcome! |
###Versions:
Question:
Hi, I'm having an issue with the Laravel IDE Helper package when generating PHPDoc for my models. The generated docblock does not include the class-level declaration (e.g., App\Models\Doctor) at the top of the docblock.
Here's an example of my Doctor model after running the command:
php artisan ide-helper:models App\Models\Doctor --write
And this is the result:
As you can see, the ### App\Models\Doctor line is missing at the top of the docblock.
I confirmed that the config/ide-helper.php file has the following settings enabled:
'write_model_external_builder_methods' => true, 'write_model_magic_where' => true, 'use_generics_annotations' => true,
Expected Output:
I expected the docblock to include the following at the top:
Question:
Is this expected behavior, or am I missing a step or configuration?
Is there a specific command or flag I need to use to include the class-level PHPDoc?
Thanks in advance for your help! Any guidance would be greatly appreciated.
The text was updated successfully, but these errors were encountered: