Missing PSR-4 autodiscovery for services in NEON for PHPStan. Do not maintain service registration manually, just dump them to generated neon config with automated command.
composer require symplify/neon-config-dumper --dev
To generate config, provide a directory with classes as first arguments, and --output-file
option path to dump the file into.
vendor/bin/config-dumper packages/phpstan-rules/src --output-file config/generated-services.neon
Tool will generate config with all services, as you'd register them manually. Directories like ValueObject
, Contract
etc. are skipped.
That's all :)
In case you are experiencing a bug or want to request a new feature head over to the Symplify monorepo issue tracker
The sources of this package are contained in the Symplify monorepo. We welcome contributions for this package on symplify/symplify.