array_indentation.rst 486 B

123456789101112131415161718192021222324252627282930313233
  1. ==========================
  2. Rule ``array_indentation``
  3. ==========================
  4. Each element of an array must be indented exactly once.
  5. Examples
  6. --------
  7. Example #1
  8. ~~~~~~~~~~
  9. .. code-block:: diff
  10. --- Original
  11. +++ New
  12. <?php
  13. $foo = [
  14. - 'bar' => [
  15. - 'baz' => true,
  16. - ],
  17. + 'bar' => [
  18. + 'baz' => true,
  19. + ],
  20. ];
  21. Rule sets
  22. ---------
  23. The rule is part of the following rule set:
  24. - `@PhpCsFixer <./../../ruleSets/PhpCsFixer.rst>`_