Skip to content

Commit

Permalink
Add Matomo Tracking to Docs site.
Browse files Browse the repository at this point in the history
Matomo is an Open Source web analytics platform that allows us
to get better insights and optimize for our audience without
the negative consequences of other compareable platforms.

Read more: https://matomo.org/why-matomo/
  • Loading branch information
cburgdorf committed Dec 9, 2019
1 parent 6d4c392 commit 757767c
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
11 changes: 11 additions & 0 deletions docs/_static/js/matomo.js
@@ -0,0 +1,11 @@
var _paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="https://matomo.ethereum.org/piwik/";
_paq.push(['setTrackerUrl', u+'matomo.php']);
_paq.push(['setSiteId', '20']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
})();
3 changes: 3 additions & 0 deletions docs/conf.py
Expand Up @@ -89,6 +89,9 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']

def setup(app):
app.add_js_file("js/matomo.js")

# Custom sidebar templates, must be a dictionary that maps document names
# to template names.
#
Expand Down

0 comments on commit 757767c

Please sign in to comment.