for doctyping a class-string you can doctype using: class-string<ParentClassType>
.
But i cannot find any documentation surrounding enums.
I can find you can document something to be a value of an Enum with value-fo<Enum>
https://phpstan.org/writing-php-code/phpdoc-types.
But is there a doctype available for enums?
(i would expect something like? enum-class
)
So the editor would know it can call ::tryFrom
, ::from
and ::cases()