I would like to set the type of unknow variables to use autocomplete and other features of Serenata.
For example:
// file_a.php
$errors = new MessageBag();
include('file_b.php');
// file_b.php
if ($errors) {
$errors->has('key');
}
In this case Serenata can't detect the type of $errors in file_b.php.
But I would like to set the type of $errors variable explicitly with a DocBlock, in order to "tell" to Serenata that I know what type is and I want to "help" her:
I would like to set the type of unknow variables to use autocomplete and other features of Serenata.
For example:
In this case Serenata can't detect the type of
$errors
infile_b.php
.But I would like to set the type of
$errors
variable explicitly with a DocBlock, in order to "tell" to Serenata that I know what type is and I want to "help" her:Or maybe a decorator in DocBlock, like: