Use modern GA loading code

This commit is contained in:
Kovid Goyal 2018-05-30 20:28:48 +05:30
parent 489ed6a915
commit 8d8224812d
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C
2 changed files with 13 additions and 1 deletions

13
docs/_templates/layout.html vendored Normal file
View file

@ -0,0 +1,13 @@
{% extends "!layout.html" %}
{%- block extrahead %}
<!-- Google Analytics -->
<script>
window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date;
ga('create', 'UA-20736318-2', 'auto');
ga('send', 'pageview');
</script>
<script async="async" src='https://www.google-analytics.com/analytics.js'></script>
<!-- End Google Analytics -->
{{ super() }}
{% endblock %}

View file

@ -114,7 +114,6 @@ html_theme_options = {
'show_powered_by': False,
'fixed_sidebar': True,
'sidebar_collapse': True,
'analytics_id': 'UA-20736318-2',
'github_button': False,
'github_banner': True,
'github_user': 'kovidgoyal',