Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/adamwojs/php-cs-fixer-phpdoc-force-fqcn

php-cs-fixer rule to force using FQCN in DocBlock comments
https://github.com/adamwojs/php-cs-fixer-phpdoc-force-fqcn

Last synced: 4 days ago
JSON representation

php-cs-fixer rule to force using FQCN in DocBlock comments

Awesome Lists containing this project

README

        

# php-cs-fixer-phpdoc-force-fqcn

[php-cs-fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer) rule to force using FQCN (Fully-Qualified Class Name) in DocBlock comments.

## Installation

You can install the package via composer:

```bash
composer require --dev adamwojs/php-cs-fixer-phpdoc-force-fqcn
```

## Usage

In your .php_cs file:

```php
registerCustomFixers([
new \AdamWojs\PhpCsFixerPhpdocForceFQCN\Fixer\Phpdoc\ForceFQCNFixer()
])
->setRules([
// ...
// (2) Enable AdamWojs/phpdoc_force_fqcn_fixer rule
'AdamWojs/phpdoc_force_fqcn_fixer' => true,
])
// ...
;
```