PHP code example of entelisteam / lbaf-rector

1. Go to this page and download the library: Download entelisteam/lbaf-rector 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/ */

    

entelisteam / lbaf-rector example snippets




declare(strict_types=1);

return \EntelisTeam\Lbaf\Rector\RectorMigrationManager::apply();



declare(strict_types=1);

namespace Vendor\MyProject\Rector;

use EntelisTeam\Lbaf\Rector\RectorMigrationListInterface;

final class MigrationList implements RectorMigrationListInterface
{
    public static function all(): array
    {
        return [
            // FQN ваших Rector-миграций
        ];
    }
}

use Rector\Configuration\RectorConfigBuilder;

final class Migration_20260513_AddStrictTypes
{
    public static function apply(RectorConfigBuilder $config): RectorConfigBuilder
    {
        return $config
            ->withRules([/* ... */]);
    }
}



declare(strict_types=1);

return \EntelisTeam\Lbaf\Rector\RectorMigrationManager::apply([
    __DIR__ . '/src',
    __DIR__ . '/tests',
]);