PHPackages                             webservco/coding-standards - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. webservco/coding-standards

ActivePhpcodesniffer-standard[PSR &amp; Standards](/categories/psr-standards)

webservco/coding-standards
==========================

Custom, opinionated coding standards based on PSR12, SlevomatCodingStandard, and PHPCompatibility.

v1.0.0(1y ago)02.4k120MITPHPPHP ^8.4

Since May 25Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/webservco/coding-standards)[ Packagist](https://packagist.org/packages/webservco/coding-standards)[ Docs](https://webserv.co)[ RSS](/packages/webservco-coding-standards/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (18)Versions (28)Used By (20)

webservco/coding-standards
==========================

[](#webservcocoding-standards)

A collection of coding standards and configuration files.

Custom, opinionated coding standards based on [PSR12](https://www.php-fig.org/psr/psr-12/), [SlevomatCodingStandard](https://github.com/slevomat/coding-standard), and [PHPCompatibility](https://github.com/PHPCompatibility/PHPCompatibility).

---

Setup
-----

[](#setup)

```
composer require --dev webservco/coding-standards
```

Optionally, install any of the dependencies from `require-dev` that you wish to use in your project.

---

Components
----------

[](#components)

[Phan](https://github.com/phan/phan)
------------------------------------

[](#phan)

Usage:

```
vendor/bin/phan --config-file vendor/webservco/coding-standards/phan/config.php
```

---

[PHP\_CodeSniffer](https://github.com/PHPCSStandards/PHP_CodeSniffer)
---------------------------------------------------------------------

[](#php_codesniffer)

Example configuration file `.phpcs/php-coding-standard.xml`, to be placed in own project:

```

	Custom, opinionated coding standards based on PSR12, SlevomatCodingStandard, and PHPCompatibility.

```

Usage:

```
vendor/bin/phpcs --standard=.phpcs/php-coding-standard.xml --extensions=php -sp bin config public resources src tests
```

Rulesets:

- `phpcs/ruleset-namespaces.xml`: Slevomat namespace usage;
- `phpcs/ruleset-psr-php74-slevomat.xml`: PHP 7.4, PSR-12, Slevomat;
- `phpcs/ruleset-psr-php81.xml`: PHP 8.1, PSR-12;
- `phpcs/ruleset-psr-php81-slevomat.xml`: PHP 8.1, PSR-12, Slevomat;
- `phpcs/ruleset-psr-php82.xml`: PHP 8.2, PSR-12;
- `phpcs/ruleset-psr-php82-slevomat.xml`: PHP 8.2, PSR-12, Slevomat;
- `phpcs/ruleset-psr-php83.xml`: PHP 8.3, PSR-12;
- `phpcs/ruleset-psr-php83-slevomat.xml`: PHP 8.3, PSR-12, Slevomat;

---

[PHPMD](https://github.com/phpmd/phpmd)
---------------------------------------

[](#phpmd)

Usage:

```
vendor/bin/phpmd bin,config,public,resources,src,tests json vendor/webservco/coding-standards/phpmd/phpmd-rule-set.xml
```

---

[PHPStan](https://github.com/phpstan/phpstan)
---------------------------------------------

[](#phpstan)

Symfony support

- install symfony related packages:
    - (if using Doctrine) "phpstan/phpstan-doctrine": "^1",
    - "phpstan/phpstan-symfony": "^1",
- (if using Doctrine) create `.phpstan/get_doctrine_manager.php`, as in phpstan-doctrine documentation
- use specific `phpstan-symfony.neon` or `phpstan-symfony-doctrine.neon` configuration files

Usage:

```
vendor/bin/phpstan analyse bin config public resources src tests --ansi -c vendor/webservco/coding-standards/phpstan/phpstan.neon --level=max
```

---

[PHPUnit](https://phpunit.de/)
------------------------------

[](#phpunit)

Composer scripts example:

```
{
	"scripts": {
		"test" : "XDEBUG_MODE=coverage vendor/bin/phpunit --colors=always --configuration vendor/webservco/coding-standards/phpunit/phpunit-10.xml --display-deprecations --display-errors --display-incomplete --display-notices --display-skipped --display-warnings",
        "test:dox" : "@test --testdox"
	}
}
```

Usage:

```
ddev xdebug on
clear && ddev exec XDEBUG_MODE=coverage composer test:dox
```

---

[Psalm](https://github.com/vimeo/psalm)
---------------------------------------

[](#psalm)

Usage:

```
vendor/bin/psalm --config=vendor/webservco/coding-standards/psalm/psalm.xml --no-diff
```

---

###  Health Score

48

—

FairBetter than 95% of packages

Maintenance69

Regular maintenance activity

Popularity19

Limited adoption so far

Community23

Small or concentrated contributor base

Maturity72

Established project with proven stability

 Bus Factor1

Top contributor holds 98.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~24 days

Recently: every ~17 days

Total

27

Last Release

457d ago

Major Versions

v0.0.44 → v1.0.02025-02-15

PHP version history (2 changes)v0.0.1PHP ^7.4||^8.1

v1.0.0PHP ^8.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/d141a82e41201dab8f836df9f4c78ad56a131c100c1ff814515d0d6f011fdecd?d=identicon)[ariademur](/maintainers/ariademur)

---

Top Contributors

[![ariademur](https://avatars.githubusercontent.com/u/34913107?v=4)](https://github.com/ariademur "ariademur (80 commits)")[![rodrigoprimo](https://avatars.githubusercontent.com/u/77215?v=4)](https://github.com/rodrigoprimo "rodrigoprimo (1 commits)")

---

Tags

Coding Standardwebservco

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Psalm

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/webservco-coding-standards/health.svg)

```
[![Health](https://phpackages.com/badges/webservco-coding-standards/health.svg)](https://phpackages.com/packages/webservco-coding-standards)
```

###  Alternatives

[league/container

A fast and intuitive dependency injection container.

86787.8M343](/packages/league-container)[stella-maris/clock

A pre-release of the proposed PSR-20 Clock-Interface

7947.5M2](/packages/stella-maris-clock)[orisai/coding-standard

Strict PHP coding standard

19193.5k62](/packages/orisai-coding-standard)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
