Closed chriscpty closed 1 month ago
Thank you for the issue. I will take a look on the problem.
I can not reproduce the problem. The plugin supports multiline variable declarations after use declaration. The problem is somewhere else. Try to press Add missed variable declarations to see what types and variables will be inserted.
I can't reproduce it anymore either, maybe it either got fixed in the meantime or i got confused because yiidea-support seems to expect there to be an @var yii\web\View $this
in the variable declarations, which I usually don't bother adding to views.
I can't reproduce it anymore either, maybe it either got fixed in the meantime or i got confused because yiidea-support seems to expect there to be an
@var yii\web\View $this
in the variable declarations, which I usually don't bother adding to views.
The latter is correct.
In the projects I work on, we always put the PHPDoc variable declarations below the use statements:
yiidea-support's "Missed PhpDoc variable declaration" inspection throws a warning as it seems to only consider PHPDocs that are at the very top of the file, before any
use
statements, meaning we have to either disable the inspection or restructure all the view files to have the variable declarations before the use statements.Perhaps the inspection should also consider variable declarations that come after
use
(and similar) statements?