Hello,
At my workplace, we currently use WordPress, but I was told by my boss to look at alternatives that we can explore.
I am currently following the documentation for the latest grav, and I am liking it at the moment.
The issue I am currently facing is the debugbar is not showing and the twig dump (I am using it in the file default.html.twig
) is not working for whatever reason
{% extends 'partials/base.html.twig' %}
{% block content %}
<pre>{{ dump(page) }}</pre>
{{ page.content|raw }}
{% endblock %}
I have enabled all the necessary settings in system.yaml
as shown below
# ...
twig:
cache: true
debug: true
auto_reload: true
autoescape: true
undefined_functions: false
undefined_filters: false
safe_functions: []
safe_filters: []
umask_fix: false
# ...
debugger:
enabled: true
provider: debugbar
censored: false
shutdown:
close_connection: true
GRAV VERSION
Grav CLI Application 1.7.48
Thanks
When you enable the debugger, look for this icon in the corner:
When you click on it, it should show all the info and debug output.
If you have Clockwork installed, even better and it shows all the data in the Dev Tools
For whatever reason, that icon does not show up for me at all
I see some differences in out of the box config:
twig:
cache: true
debug: true
auto_reload: true
autoescape: true
undefined_functions: true
undefined_filters: true
safe_functions: { }
safe_filters: { }
umask_fix: false
debugger:
enabled: true
provider: debugbar
censored: false
shutdown:
close_connection: true
twig: true
Try adding:
debugger:
twig: true
BTW, is this valid at all?
safe_filters: [] filters
Yes, I have added this
debugger:
twig: true
but it is still not working
And sorry this (safe_filters: [] filters
) is a typo on my part (Fixed it)
Does it work on fresh Grav install? If so, try disabling plugins maybe one by one
No, I have tried a fresh install and nothing seems to be working
Hello, I’m a newbie myself just started out a couple of days.
I saw this one, and I believe I saw what is missing here. In order to use clockwork:
debugger:
enabled: true
provider: clockwork
The provider must be set to clockwork.
It’s most likely much to late for this answer. But I thought I post anyways, because someone from the future might find this helpful.