Skip to content

Commit

Permalink
✨ Create a dedicated cache for the bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
ker0x committed Nov 18, 2023
1 parent 3439a10 commit 031a9c4
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions src/Bridge/Symfony/Bundle/Resources/config/tailwind.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,17 @@

return static function (ContainerConfigurator $container) {
$container->services()
->set('twig.cache.tailwind')
->parent('cache.app')
->tag('cache.pool', ['name' => 'twig.cache'])

->set('twig.extension.tailwind', TailwindExtension::class)
->tag('twig.extension')
->tag('twig.extension')

->set('twig.runtime.tailwind', TailwindRuntime::class)
->args([
service('twig.cache'),
])
->tag('twig.runtime')
->args([
service('twig.cache.tailwind'),
])
->tag('twig.runtime')
;
};

0 comments on commit 031a9c4

Please sign in to comment.