{% if parent.defined_template_name -%} {{ "{% extends '" }}{{ parent.defined_template_name }}{{ "' %}" }} {%- else -%} {{ "{% extends '" + app_name + "/base.html' %}" }} {%- endif %} {%- if page.template_libs %} {{ "{% load " }}{{ ' '.join(page.template_libs) }}{{ " %}" }} {%- endif %} {% for area, blocks in page.blocks.items() -%} {{ "{% block " }}{{ area }}{{ " %}" }} {% for block in blocks -%} {% if block.name == '..' -%} {{ super() }} {%- else -%} {{ block.render(area=area, index=loop.index) }} {%- endif %} {%- endfor %} {{ "{% endblock %}" }} {%- endfor %} {% if page.react_client %} {{ "{% block js %}{{ block.super }}" }} {{ "{% endblock %}" }} {% endif %}