-
Notifications
You must be signed in to change notification settings - Fork 10
/
.php-cs-fixer.php
45 lines (44 loc) · 1.72 KB
/
.php-cs-fixer.php
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
return (new PhpCsFixer\Config())
->setRules([
'@PSR12' => true,
'array_indentation' => true,
'blank_line_after_opening_tag' => true,
'combine_consecutive_issets' => true,
'combine_consecutive_unsets' => true,
'class_attributes_separation' => ['elements' => ['method' => 'one']],
'single_quote' => true,
'binary_operator_spaces' => [
'default' => 'single_space',
'operators' => [
'=>' => 'align_single_space_minimal'
]
],
'braces' => [
'allow_single_line_closure' => true
],
'concat_space' => true,
'include' => true,
'lowercase_cast' => true,
'no_extra_blank_lines' => [
'tokens' => [
'curly_brace_block',
'extra',
'parenthesis_brace_block',
'square_brace_block',
'throw',
'use'
]
],
'no_multiline_whitespace_around_double_arrow' => true,
'no_whitespace_in_blank_line' => true,
'object_operator_without_whitespace' => true,
'ternary_operator_spaces' => true,
'trim_array_spaces' => true,
'lowercase_static_reference' => true,
'no_superfluous_elseif' => true,
'no_useless_else' => true,
'no_useless_return' => true,
'trailing_comma_in_multiline' => false
])
->setLineEnding(PHP_EOL);