Run Rector on your code to see what it can do for you:

 <?php
-/**
- * @var \App\View\AppView $this
- * @var array<\App\Model\SomeEntity> $sickDays
- */
 foreach ($sickDays as $vacation): ?>
     <div class="leading-6"><?= $vacation->start_datetime->i18nFormat('EEEE, dd. MMMM YYYY') ?></div>
 <?php endforeach; ?>
PHP snippet to change

Applied Rules:

Not a change you expect?

Config  rector.php
Rector version: 2fecbc - released at 2026-01-05 10:26