Python Django-在include中解包字典
我想在include标签中打开词典Python Django-在include中解包字典,python,django,django-templates,Python,Django,Django Templates,我想在include标签中打开词典 # Python kwargs = {"dictionary": "vertical"} # Template {% include "test.html" with kwargs %} {# This should be turned into this #} {% include "test.html" with dictionary=vertical %} 这是否可能仅使用包含标记
# Python
kwargs = {"dictionary": "vertical"}
# Template
{% include "test.html" with kwargs %}
{# This should be turned into this #}
{% include "test.html" with dictionary=vertical %}
这是否可能仅使用包含标记