perf: add twig caching

This commit is contained in:
David Bailey 2024-01-11 16:55:19 +01:00
parent 7f2c7edf76
commit 614bf9d3b6
2 changed files with 4 additions and 4 deletions

View file

@ -24,7 +24,7 @@ $adapter = new PostHandler($SITE_CONFIG);
$loader = new \Twig\Loader\FilesystemLoader(['./templates', './user_content']);
$twig = new \Twig\Environment($loader,['debug' => true]);
$twig = new \Twig\Environment($loader,['cache' => 'twig_cache']);
$twig->addExtension(new Twig\Extra\Markdown\MarkdownExtension());
use Twig\Extra\Markdown\DefaultMarkdown;