des1roer Asked:2022-04-19 13:18:36 +0000 UTC2022-04-19 13:18:36 +0000 UTC 2022-04-19 13:18:36 +0000 UTC 如何将\放在PHP中所有函数的前面? 772 在项目中,为了统一起见,决定在函数前使用斜线,即 \array_filter、\in_array https://github.com/symplify/easy-coding-standard和 symfony使用 php 1 个回答 Voted Best Answer des1roer 2022-04-19T13:19:43Z2022-04-19T13:19:43Z 在 ecs.php 中 return static function (ContainerConfigurator $containerConfigurator): void { $services = $containerConfigurator->services(); $services->set(\PhpCsFixer\Fixer\FunctionNotation\NativeFunctionInvocationFixer::class)->call('configure', [[ 'include' => [\PhpCsFixer\Fixer\FunctionNotation\NativeFunctionInvocationFixer::SET_INTERNAL], ]]); };
在 ecs.php 中