Search by

timmit / phpcs-framework-rules

timmit

PHPCS rules shared by aItem applications.

Package info

github.com/timmit-nl/phpcs-framework-rules

Type:phpcodesniffer-standard

pkg:composer/timmit/phpcs-framework-rules

Statistics

Installs: 1 191

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.1.1 2026-11-27 10:49 UTC

This package is auto-updated.

Last update: 2026-11-27 10:52:38 UTC


README

PHPCS rules shared by applications on an aItem based framework.

Install

composer require --dev timmit/phpcs-framework-rules

Allow the PHPCS Composer installer in the root composer.json:

{
    "config": {
        "allow-plugins": {
            "dealerdirect/phpcodesniffer-composer-installer": true
        }
    }
}

The installer registers the TiMMiT standard. Check with vendor/bin/phpcs -i.

Usage

PSR1 includes Squiz.Classes.ValidClassName, which only allows PascalCase. Exclude that sniff and use this standard instead:

<rule ref="PSR1">
    <exclude name="Squiz.Classes.ValidClassName"/>
</rule>

<rule ref="TiMMiT"/>

Class names

Kind Name
Abstract class lowercase a, then PascalCase: aItem, aConnector
Trait lowercase t, then PascalCase: tItem
Interface lowercase i, then PascalCase: iProvider, iCorrespondence
Class, enum PascalCase: Sim

aitem, titem and iprovider are still reported: the part after the prefix must be PascalCase.