Rule phpdoc_indent
¶
Docblocks should have the same indentation as the documented subject.
Examples¶
Example #1¶
--- Original
+++ New
<?php
class DocBlocks
{
-/**
- * Test constants
- */
+ /**
+ * Test constants
+ */
const INDENT = 1;
}
Rule sets¶
The rule is part of the following rule sets:
References¶
Fixer class: PhpCsFixer\Fixer\Phpdoc\PhpdocIndentFixer
Test class: PhpCsFixer\Tests\Fixer\Phpdoc\PhpdocIndentFixerTest
The test class defines officially supported behaviour. Each test case is a part of our backward compatibility promise.