如何在 PhpStorm IDE 中更改 PHP 代码风格?

How to change PHP code style in PhpStorm IDE?

我正在使用 Laravel 框架。我想从这里更改默认代码样式格式:

 return [
            'name' => 'required|min:4|string',
            'email' => 'required|email|unique:users,email',
            'password' => 'required|min:4|confirmed',
            'password-confirmation' => 'required|min:4'
        ];

到这个:

return [
            'name'                  => 'required|min:4|string',
            'email'                 => 'required|email|unique:users,email',
            'password'              => 'required|min:4|confirmed',
            'password-confirmation' => 'required|min:4'
        ];

我在 PhpStorm 设置中进行了大量搜索,但找不到解决方案。

  1. File | Settings(macOS 上PhpStorm | Preferences
  2. Editor | Code Style | PHP
  3. Wrapping and Braces 选项卡
  4. Array initializer | Align key-value pairs 选项