Moved Google Analytics block into head

This commit is contained in:
squidfunk 2019-01-28 11:18:22 +01:00
parent 2f31618d60
commit 5ec6ad2828
2 changed files with 12 additions and 12 deletions

View File

@ -85,6 +85,11 @@
{% for path in config["extra_css"] %} {% for path in config["extra_css"] %}
<link rel="stylesheet" href="{{ path | url }}"> <link rel="stylesheet" href="{{ path | url }}">
{% endfor %} {% endfor %}
{% block analytics %}
{% if config.google_analytics %}
{% include "partials/integrations/analytics.html" %}
{% endif %}
{% endblock %}
{% block extrahead %}{% endblock %} {% block extrahead %}{% endblock %}
</head> </head>
{% if palette.primary or palette.accent %} {% if palette.primary or palette.accent %}
@ -211,10 +216,5 @@
<script src="{{ path | url }}"></script> <script src="{{ path | url }}"></script>
{% endfor %} {% endfor %}
{% endblock %} {% endblock %}
{% block analytics %}
{% if config.google_analytics %}
{% include "partials/integrations/analytics.html" %}
{% endif %}
{% endblock %}
</body> </body>
</html> </html>

View File

@ -173,6 +173,13 @@
<link rel="stylesheet" type="text/css" href="{{ path | url }}" /> <link rel="stylesheet" type="text/css" href="{{ path | url }}" />
{% endfor %} {% endfor %}
<!-- Analytic scripts -->
{% block analytics %}
{% if config.google_analytics %}
{% include "partials/integrations/analytics.html" %}
{% endif %}
{% endblock %}
<!-- Custom front matter --> <!-- Custom front matter -->
{% block extrahead %}{% endblock %} {% block extrahead %}{% endblock %}
</head> </head>
@ -378,12 +385,5 @@
<script src="{{ path | url }}"></script> <script src="{{ path | url }}"></script>
{% endfor %} {% endfor %}
{% endblock %} {% endblock %}
<!-- Analytic scripts -->
{% block analytics %}
{% if config.google_analytics %}
{% include "partials/integrations/analytics.html" %}
{% endif %}
{% endblock %}
</body> </body>
</html> </html>