PHP code example of mlencki / ecs-config

1. Go to this page and download the library: Download mlencki/ecs-config 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/ */

    

mlencki / ecs-config example snippets




declare(strict_types=1);

use MLencki\CodeStyle\EasyCodingStandard\Config;

$config = new Config();
$config->scanPaths(['src', 'tests']);

return $config->get();



declare(strict_types=1);

use MLencki\CodeStyle\Rector\Config;
use Rector\Core\Configuration\Option;

$config = new Config();
$config->scanPaths(['src', 'tests']);
$config->setOption(Option::AUTOLOAD_PATHS, ['tests']);

return $config->get();
bash
docker-compose run php composer install
bash
docker-compose run php composer ecs
bash
docker-compose run php composer tests