Skip to content

Commit 43be19c

Browse files
committed
style(config): 优化 PHP CS Fixer 配置规则
1 parent 14da1a7 commit 43be19c

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

.php-cs-fixer.dist.php

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,12 @@
99

1010
return (new Config())
1111
->setRules([
12-
'@PhpCsFixer' => true,
13-
'binary_operator_spaces' => [
14-
'default' => 'align_single_space_minimal',
12+
'@PhpCsFixer' => true,
13+
'binary_operator_spaces' => [
14+
'default' => 'align_single_space_minimal',
15+
'operators' => [
16+
'=>' => 'align_single_space_minimal_by_scope',
17+
],
1518
],
1619
'blank_line_before_statement' => [
1720
'statements' => [
@@ -22,10 +25,10 @@
2225
'try',
2326
],
2427
],
25-
'concat_space' => [
28+
'concat_space' => [
2629
'spacing' => 'one',
2730
],
28-
'global_namespace_import' => [
31+
'global_namespace_import' => [
2932
'import_classes' => true,
3033
'import_constants' => false,
3134
'import_functions' => false,

0 commit comments

Comments
 (0)