What problem does it solve?
It prevents inconsistent, error-prone PHP style by enforcing a single set of house rules for PHP 8.3+ production code.
Core Features & Use Cases
- Standardized production PHP guidance: enforces final + readonly defaults, typed class constants, strict naming conventions, and consistent imports to reduce review churn.
- Year-to-year PHP correctness: documents load-bearing PHP 8.4+ behaviors and gotchas (e.g., property hooks, asymmetric visibility, new array functions) so code matches the intended runtime.
- Quality tooling alignment: codifies expectations for Composer constraints, Pint/ordered imports, PHPStan max discipline, Rector migrations, PHPUnit 12 attribute practices, and typed exceptions.
Quick Start
Use php-expert when you want feedback on an existing PHP file’s conventions and production-readiness (naming, typing, overrides, exceptions, tests) or when you need to implement new code that fits the repo’s house patterns.