Use configuration variable in a presenter

materix
Backer | 83
+
0
-

In bootstrap.php I have $configurator->addConfig('config.neon');.

Let say I add a custom value to config.neon, e.g. “appname:MegaSite”, and want to use this variable in a template.

How do I reference a variable from configuration in a presenter?

David Grudl
Nette Core | 8218
+
0
-

Pass it to the presenter https://blog.nette.org/…-to-services

materix
Backer | 83
+
0
-

Thanks, it worked!

Dependency injection is the most difficult part of Nette to understand, but I am getting there :-)