This commit is contained in:
lubiana 2025-06-08 13:58:51 +02:00
parent 837cfb6d43
commit 939840a3ac
Signed by: lubiana
SSH key fingerprint: SHA256:vW1EA0fRR3Fw+dD/sM0K+x3Il2gSry6YRYHqOeQwrfk
76 changed files with 6636 additions and 83 deletions

16
config/packages/twig.php Normal file
View file

@ -0,0 +1,16 @@
<?php
declare(strict_types=1);
use App\Service\Config\AppName;
use Symfony\Config\TwigConfig;
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
return static function (ContainerConfigurator $containerConfigurator, TwigConfig $twig): void {
$twig->fileNamePattern('*.twig');
$twig->formThemes(['bootstrap_5_layout.html.twig']);
$twig->global('appName', \Symfony\Component\DependencyInjection\Loader\Configurator\service(AppName::class));
if ($containerConfigurator->env() === 'test') {
$twig->strictVariables(true);
}
};