Muut
1
Hi guys,
Any ideas on which is the best way to get the version number of the active theme using Twig ? My best attempt so far is:
{% set themeobj = grav['themes'] %}
{% set themeinfo = themeobj.get(config.system.pages.theme).blueprints %}
<p id="theme-about">{{ themeinfo.name }} {{ themeinfo.version }}<p>
But it doesn’t feel very idiomatic. I’m maybe missing something here.
Thank you very much for your time and help,
Muut
2
AFAIK that’s the only way now, maybe we can add this information to the Theme object, so it’s more easily accessible using grav.theme
@rhukster?
Muut
3
Thank you for your quick reply @flaviocopes. +1 to have a shortcut through grav.theme
Muut
4
Please create an issue for this feature request here: https://github.com/getgrav/grav/issues