PHP code example of guanguans / php-cs-fixer-custom-fixers

1. Go to this page and download the library: Download guanguans/php-cs-fixer-custom-fixers library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

guanguans / php-cs-fixer-custom-fixers example snippets

diff
 
 return (new PhpCsFixer\Config())
+    ->registerCustomFixers($fixers = Guanguans\PhpCsFixerCustomFixers\Fixers::make())
     ->setRules([
         '@PhpCsFixer:risky' => true,
+        Guanguans\PhpCsFixerCustomFixers\Fixer\CommandLineTool\BladeFormatterFixer::name() => true,
+        Guanguans\PhpCsFixerCustomFixers\Fixer\CommandLineTool\YamlfmtFixer::name() => true,
+        // Other fixers...
     ])
     ->setFinder(
         PhpCsFixer\Finder::create()
             ->in(__DIR__)
+            // ->name(Guanguans\PhpCsFixerCustomFixers\Fixer\CommandLineTool\BladeFormatterFixer::make()->extensionPatterns())
+            // ->name(Guanguans\PhpCsFixerCustomFixers\Fixer\CommandLineTool\YamlfmtFixer::make()->extensionPatterns())
+            // Other ...
+            ->name($fixers->extensionPatterns())
    );
diff
-<phpunit bootstrap="vendor/autoload.php" colors="true" failOnDeprecation="true" failOnRisky="true" failOnWarning="true">
+<?xml version="1.0" encoding="UTF-8"
diff
-<phpunit bootstrap="vendor/autoload.php" colors="true" failOnDeprecation="true" failOnRisky="true" failOnWarning="true">
+<?xml version="1.0" encoding="UTF-8"