forked from rectorphp/rector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ecs-after-rector.yaml
28 lines (21 loc) · 1.07 KB
/
ecs-after-rector.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
services:
# remove unused "use" statements
PhpCsFixer\Fixer\Import\NoUnusedImportsFixer: ~
# order use statements A-Z
PhpCsFixer\Fixer\Import\OrderedImportsFixer: ~
# remove leading slash ("\") at imports
PhpCsFixer\Fixer\Import\NoLeadingImportSlashFixer: ~
# remove extra spaces from DocBlocks
PhpCsFixer\Fixer\Comment\NoTrailingWhitespaceInCommentFixer: ~
# clean empty doc blocks, e.g. after annotation removal
PhpCsFixer\Fixer\Phpdoc\NoEmptyPhpdocFixer: ~
# import namespaces for classes, constants and functions
# configuration: https://github.com/slevomat/coding-standard#slevomatcodingstandardnamespacesreferenceusednamesonly-
SlevomatCodingStandard\Sniffs\Namespaces\ReferenceUsedNamesOnlySniff:
searchAnnotations: true
allowFallbackGlobalFunctions: true
allowFallbackGlobalConstants: true
# add spaces between class elements
PhpCsFixer\Fixer\ClassNotation\ClassAttributesSeparationFixer: ~
# add declare strict types to start of the file
PhpCsFixer\Fixer\Strict\DeclareStrictTypesFixer: ~