Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
IconCacheTwigFilter example
$loader
,
sys_get_temp_dir
(
)
. '/twig_test_' .
microtime
(
true
)
,
new
NamespaceHierarchyBuilder
(
[
$builder
,
]
)
,
$scopeDetector
,
)
;
$twig
->
addExtension
(
new
NodeExtension
(
$templateFinder
,
$scopeDetector
)
)
;
$twig
->
getExtension
(
NodeExtension::
class
)
->
getFinder
(
)
;
$twig
->
addExtension
(
new
IconCacheTwigFilter
(
)
)
;
$twig
->
addExtension
(
new
IconExtension
(
$templateFinder
)
)
;
return
$twig
;
}
}
/** * @internal */
class
TestController
extends
StorefrontController
{