{% load common_filters %} {% load common_tags %} {% load static %} {% viewport %} {% if env != "production" %}{% endif %} {% if self.search_description %} {% endif %} {% if metadata %} {% endif %} {% if require_privacy_consent %} {% endif %} {% if encode_email_addresses %} {% endif %} {% spaceless %} {% comment %} JS config - Ignore error from Outlook SafeLink crawler. Don't ignore the generic "Non-Error promise rejection" since that could apply to other errors. https://github.com/cefsharp/CefSharp/blob/d8674fd076c021eddcc0cb579687ca3c51a63767/CefSharp/Internals/JavascriptObjectRepository.cs#L293 */ {% endcomment %} {% if not request.is_preview and ga_tracking_id %} {% comment %} Work around https://code.djangoproject.com/ticket/28172 by making sure a variable always exists. {% endcomment %} {% capture as common_head_consent_group %}{{ google_consent_group }}{% endcapture %} {% requireconsent group=common_head_consent_group %} {% if env == "production" %} {% comment %} Global Site Tag {% endcomment %} {% if use_gtag %} {% comment %} Google Tag Manager {% endcomment %} {% elif use_gtm %} {% comment %} IP anonymization is done via tag configuration settings by adding an 'anonymizeIp' field with value 'true', can't be set via code. {% endcomment %} {% comment %} Universal Analytics {% endcomment %} {% else %} {% endif %} {% else %} {% endif %} {% endrequireconsent %} {% endif %} {% endspaceless %}