Fork me on GitHub
a Sensio Labs Product

Remote Void (v2.18.1) edition

Rule phpdoc_inline_tag_normalizer

Fixes PHPDoc inline tags.

Configuration

tags

The list of tags to normalize

Allowed types: array

Default value: ['example', 'id', 'internal', 'inheritdoc', 'inheritdocs', 'link', 'source', 'toc', 'tutorial']

Examples

Example #1

Default configuration.

--- Original
+++ New
@@ -1,6 +1,6 @@
 <?php
 /**
- * @{TUTORIAL}
- * {{ @link }}
+ * {@TUTORIAL}
+ * {@link}
  * @inheritDoc
  */

Example #2

With configuration: ['tags' => ['TUTORIAL']].

--- Original
+++ New
@@ -1,6 +1,6 @@
 <?php
 /**
- * @{TUTORIAL}
+ * {@TUTORIAL}
  * {{ @link }}
  * @inheritDoc
  */

Rule sets

The rule is part of the following rule sets:

@PhpCsFixer

Using the @PhpCsFixer rule set will enable the phpdoc_inline_tag_normalizer rule with the default config.

@Symfony

Using the @Symfony rule set will enable the phpdoc_inline_tag_normalizer rule with the default config.

The logo is © 2010-2014 Sensio Labs