friendsofphp/php-cs-fixer
PHP CS Fixer automatically detects and fixes PHP coding style issues, applying built-in rule sets (PER-CS, Symfony, PhpCsFixer) or custom configs. Helps modernize code for newer PHP/PHPUnit. Install via Composer; supports PHP 7.4–8.5.
@autoPHPMigration to incrementally adopt newer PHP features (e.g., attributes, typed properties) without breaking changes.@autoPHPMigration to prepare for PHP 8.3+ features.Adopt if:
Look elsewhere if:
[email protected]).*"PHP-CS-Fixer is a force multiplier for our engineering team. It automates 90% of code style enforcement—saving 10+ dev-hours/month on manual reviews. By standardizing our codebase, we’ll:
*"This replaces PHP_CodeSniffer + manual fixes with a self-healing linter. Key wins:
php-cs-fixer fix) auto-fixes PSR-12, Symfony, or custom rules.@autoPHPMigration to safely adopt PHP 8.3+ features.@Symfony rules in CI (fail builds on violations).@autoPHPMigration for new features.
No trade-offs—it’s battle-tested (used by Symfony, Laravel, and 13K+ repos)."**"This solves three pain points:
if (true) { ... } vs. if (true) {...}.#[Deprecated] attributes).php-cs-fixer init to generate a .php-cs-fixer.dist.php config.--dry-run first.fix vs. check modes.
Risk: Minimal—it’s non-destructive (only fixes, doesn’t rewrite logic)."*How can I help you explore Laravel packages today?