See available Laravel rules
This package is a Rector extension developed by the Laravel community.
Install the RectorLaravel
package as dependency:
composer require driftingly/rector-laravel --dev
To add a set to your config, use RectorLaravel\Set\LaravelSetList
class and pick one of the constants:
<?php
declare(strict_types=1);
use Rector\Config\RectorConfig;
use RectorLaravel\Set\LaravelSetList;
return RectorConfig::configure()
->withSets([
LaravelSetList::LARAVEL_110
]);
Rector is a tool that we develop and share for free, so anyone can save hundreds of hours on refactoring. But not everyone has time to understand Rector and AST complexity. You have 2 ways to speed this process up:
- Read the book - The Power of Automated Refactoring
- Hire our experienced team to improve your codebase
Both ways support us to and improve Rector in sustainable way by learning from practical projects.