{% if app.request.isXmlHttpRequest() %}
    {% set tplExtends = "empty.html.twig" %}
{% else %}
    {% set tplExtends = "homepage.html.twig" %}
{% endif %}

{% extends tplExtends %}

{% block mainBody %}
<div>
    {% block mainContent %}{% endblock %}
</div>
{% endblock %}
