PHP code example of sugared-rim / php-cs-fixer

1. Go to this page and download the library: Download sugared-rim/php-cs-fixer 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/ */

    

sugared-rim / php-cs-fixer example snippets

json
{
    ...
    "im/php-cs-fixer": ...
    },
    "scripts": {
        "lint": "sugared-rim-php-cs-fixer"
    }
}
json
{
    ...
    "scripts": {
        "lint": "sugared-rim-php-cs-fixer"
    },
    "extra": {
        "sugared-rim/php-cs-fixer": {
            "diff": true,
            "dry-run": true,
            "cache": true,
            "path": {
                "in": [
                    "."
                ],
                "name": [
                    "*.php",
                    "*.phtml",
                    "*.twig",
                    "*.xml",
                    "*.yml"
                ],
                "exclude": [
                    "build",
                    "bower_components",
                    "node_modules",
                    "vendor"
                ],
                "ignoreDotFiles": true,
                "ignoreVCS": true
            }
        }
    }
}