appears to be in antimatter.yaml
i wanted to access the theme config from within a modu,le twig file (eg showcase.html.twig) but the variable is not defined here. I see that module extends partial/base which defines this variable. so i assumed it would be defined. but no.
sorry, this is due to my lack of twig understanding. I do think that the config should be accessilble from the modules.
Archive
You can access any configuration from anywhere, you just need to know how.. it's pretty easy from twig:
TWIG
{% set dropdown_status = grav.config.themes.antimatter.dropdown.enabled %}
To know what and where things are you can look in the cached config object that represents all configuration as big array in cache/compiled/config/master-localhost.php (or whatever it's called for you)
thanks for the tip!
Log in to reply.
Suggested topics
| Topic | Participants | Replies | Views | Activity |
|---|---|---|---|---|
| 0 | 1346 | 9 years ago | ||
| 2 | 933 | 9 years ago | ||
| 2 | 4060 | 9 years ago | ||
| 1 | 2945 | 9 years ago | ||
| 3 | 1117 | 9 years ago |