Try Rector
Documentation
Hire Team
Blog
Contact
Try Rector
Documentation
Hire Team
Blog
Contact
Run Rector on your code to see what it can do for you:
// no change
PHP snippet to change
<?php class TestController extends AbstractController { /** * This is an example comment * * @Route("/test", name="test_route") */ public function test(): Response { return $this->render("test.html.twig", [ ]); } }
Config
rector.php
<?php use Rector\Config\RectorConfig; use Rector\TypeDeclaration\Rector\Property\TypedPropertyFromAssignsRector; use Rector\ValueObject\PhpVersion; return RectorConfig::configure() ->withAttributesSets( symfonyRoute: true, );
Run Rector
Rector version:
e4cb24
- released at 2026-06-25 18:47