Files
archived-ux.symfony.com/phpstan.dist.neon
Hugo Alliaume 1d73c40173 Add PHPStan
2026-01-24 09:09:38 +01:00

43 lines
1.6 KiB
Plaintext

includes:
- vendor/phpstan/phpstan-doctrine/extension.neon
- vendor/phpstan/phpstan-symfony/extension.neon
- vendor/kocal/phpstan-symfony-ux/extension.neon
- tools/phpstan/symfony-configuration.php
parameters:
level: 6
paths:
- bin/
- config/
- public/
- src/
- tests/
excludePaths:
- config/reference.php
doctrine:
objectManagerLoader: tools/phpstan/object-manager.php
ignoreErrors:
- message: '#Method .+::test.+\(\) has no return type specified\.#'
paths:
- tests/
rules:
# LiveComponent rules
- Kocal\PHPStanSymfonyUX\Rules\LiveComponent\LiveActionMethodsVisibilityRule
- Kocal\PHPStanSymfonyUX\Rules\LiveComponent\LiveListenerMethodsVisibilityRule
- Kocal\PHPStanSymfonyUX\Rules\LiveComponent\LivePropHydrationMethodsRule
- Kocal\PHPStanSymfonyUX\Rules\LiveComponent\LivePropModifierMethodRule
# TwigComponent rules
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\ClassMustBeFinalRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\ClassNameMustNotEndWithComponentRule
# ExposePublicPropsMustBeFalseRule is NOT enabled as requested
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\ForbiddenAttributesPropertyRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\ForbiddenClassPropertyRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\MethodsVisibilityRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\PostMountMethodSignatureRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\PreMountMethodSignatureRule
- Kocal\PHPStanSymfonyUX\Rules\TwigComponent\PublicPropertiesMustBeCamelCaseRule