codeigniter/coding-standard
Official coding standard for CodeIgniter 4, built on PHP_CodeSniffer. It enforces consistent PHP code style and quality across CodeIgniter projects, with rules aligned to the framework's conventions and easy integration into Composer workflows.
What it is. codeigniter/coding-standard is the official CodeIgniter 4 coding standard, distributed as a Composer dev dependency. It ships a PHP CS Fixer ruleset class plus a default config, so adoption is composer require --dev + a .php-cs-fixer.dist.php that references the ruleset. There is no runtime code path, no service registration, and no production footprint.
Architecture fit. As a dev-time quality tool, architectural risk is deliberately confined to the toolchain: it cannot affect request handling, autoloading in prod, or deployment artifacts if installed with --dev and omitted from composer install --no-dev. The mismatch to flag is framework intent: this ruleset encodes CodeIgniter 4 idioms, not Laravel idioms. For a Laravel-first estate, the canonical answer is laravel/pint (itself a PHP CS Fixer wrapper with a Laravel preset). This package is a fit only if (a) the estate contains CodeIgniter 4 applications, or (b) we are deliberately cherry-picking its PSR-12-aligned rules into a shared baseline. It is not a drop-in Laravel standard.
Integration feasibility. Mechanically high: single dev dependency, one config file, one CI step. Organizationally medium-to-low for Laravel teams, because it competes with Pint for the same job and the same underlying friendsofphp/php-cs-fixer dependency.
Technical risk.
composer.json is a realistic conflict. Blast radius is CI, not production..git-blame-ignore-revs.Key questions for the team.
Stack fit. PHP 8.x + Composer, framework-agnostic at the tooling layer. Correct placement is require-dev, executed in CI and optionally in a pre-commit hook. It replaces ad-hoc php-cs-fixer configs; it does not replace static analysis (PHPStan/Psalm) or tests.
Recommended segmentation.
laravel/pint as the default.composer.json. If both standards must exist in one monorepo, run each in its own tooling image/PHAR rather than resolving fixer versions in a shared lockfile.Migration path (per repo).
vendor/bin/php-cs-fixer fix --dry-run --diff and record file/line counts..git-blame-ignore-revs.Compatibility checks before commitment.
.editorconfig/.php-cs-fixer.php files.Sequencing. Pilot (1 sprint) → governance note documenting where each standard applies (1–2 days TPM/tech-lead effort) → wave rollout by team → quarterly ruleset review aligned with dependency upgrades. Keep the blocking gate off until the baseline commit is merged everywhere it applies.
Maintenance. Low ongoing effort: Dependabot/Renovate for the fixer and ruleset, plus a scheduled minor bump per quarter. Real cost is the upgrade review, not the day-to-day. Budget roughly 0.5–1 engineer-day per quarter for a mid-size estate.
Support. Maintained by the CodeIgniter core team under MIT; no commercial SLA. With 74 stars and no listed dependents, the bus factor and community backstop are thin. Acceptable for a dev-only tool where a fallback (plain PHP CS Fixer with a checked-in rule array) exists in an afternoon.
Scaling. Effectively free. Runs are seconds-to-low-minutes per repo; use the .php-cs-fixer.cache file in CI, and shard by directory in monorepos. It scales linearly with repo count and does not interact with runtime capacity.
Failure modes.
--dry-run exit handling) — formatting debt accumulates invisibly.--no-verify; the CI gate must be authoritative.Ramp-up. Minimal for developers — a short README note and one command. TPM/tech-lead effort is front-loaded: pilot coordination, the segmentation decision (Pint vs. this package), and the governance doc. Estimate 1–2 days of PM time plus one sprint of engineering attention for the pilot and baseline.
TPM recommendation. Do not adopt this as the primary standard for a Laravel codebase; Pint is the lower-risk default there. Adopt it only for CodeIgniter 4 repos, and treat it as a reference ruleset for shared PHP libraries. The package is technically sound and cheap to operate, but its small ecosystem footprint means the decision should rest on "do we run CodeIgniter 4?" rather than on its score.
How can I help you explore Laravel packages today?