| What it is | Runs PHP_CodeSniffer and PHP-CS-Fixer rules together, fast | Extra PHP_CodeSniffer sniffs for safer, cleaner and consistently formatted PHP | Detect and fix coding standard violations in PHP | The Laminas Project's PHP_CodeSniffer coding standard ruleset, built on PSR-12 |
| Features | - runs PHP_CodeSniffer and PHP-CS-Fixer rules in one tool
- one ecs.php config, created on first run
- prepared sets: PSR-12, PER Coding Style, Laravel and topic sets
- parallel runs and a bundled Go engine (--blink)
- works on PHP 7.2 to 8.5 projects
| - functional sniffs that improve code safety and behaviour
- cleaning sniffs that detect dead code
- formatting sniffs for consistent code style
- automatic fixing for many sniffs
- local suppression of sniff checks
| - phpcs detects coding standard violations
- phpcbf fixes them automatically
- built-in standards and custom rulesets
- project configuration files
- signed PHAR downloads and Composer
| - a PHP_CodeSniffer ruleset extending PSR-12 and requiring PSR-1
- rules for operator whitespace, array and object alignment and multi-line conditionals
- rules for what to import and how
- fix violations automatically with phpcbf
|