inviqa / phpstan-magento2
Extension for PHPStan to allow analysis of Magento2 code.
Installs: 56 216
Dependents: 0
Suggesters: 0
Security: 0
Stars: 4
Watchers: 8
Forks: 2
Open Issues: 2
Requires
This package is auto-updated.
Last update: 2024-10-23 01:49:20 UTC
README
Extension for PHPStan to allow analysis of Magento2 code.
This is fairly bare-bones at the moment, just bootstrapping Magento
Usage
Add phpstan.neon
to your Magento2 project.
Make sure it has
includes: - vendor/inviqa/phpstan-magento2/extension.neon
Whilst this extension depends on phpstan/phpstan, it can also depend on phpstan/phpstan-shim, which decouples its dependencies from Magento's own use of them. Some versions of Magento 2 will require the latter due to conflicting symfony/console version constraints.
With coupled dependencies:
composer require inviqa/phpstan-magento2 phpstan/phpstan
With uncoupled phar package:
composer require inviqa/phpstan-magento2 phpstan/phpstan-shim