{% if not hide_from_sitemap(entry) %}
    <url>
        <loc>{{ url('_slug', { '_locale': locale, 'url': entry.slug }) }}</loc>
        <lastmod>{{ entry.nodeTranslation.getPublicNodeVersion().getUpdated()|date('Y-m-d') }}</lastmod>
        <priority>{{ "0." ~ priority }}</priority>
    </url>
{% endif %}
{% if not hide_children_from_sitemap(entry) %}
    {% for subNode in entry.getChildren() %}
        {% include '@KunstmaanSitemap/Sitemap/entry.xml.twig' with {'entry' : subNode, 'priority' : (priority - 1) } %}
    {% endfor %}
{% endif %}
