1👍
✅
This is a perfect use case for django-debug-toolbar.
Template panel shows templates and context used, and their template paths.
Or, alternatively, just print out the values you want to see:
{% for category in categories %}
{{ category }}
...
{% endfor %}
Hope that helps.
Source:stackexchange.com