Nette 2.1 > 2.2 nette.latte macro install in config.neon
Notice: This thread is very old.
- mcmatak
- Member | 504
i am used to install macros in config.neon
nette.latte:
class: \Nette\Latte\Engine
autowired: no
setup:
- \System\Templates\LatteMacros::install(::$service->getCompiler())
- \System\Application\Templates\ImageManager\ImageManagerMacro::install(::$service->getCompiler())
is there a similar way in Nette 2.2 ?
- David Grudl
- Nette Core | 8252
Dej to do služby nette.latteFactory
.
Ten zápis ::$service->getCompiler()
by správně neměl
fungoval, korektní je @self::getCompiler
.
- David Grudl
- Nette Core | 8252
Proč to neděláš standardní cestou? https://doc.nette.org/en/configuring#…