[DOCS] add Matomo analytics (#20438)

This commit is contained in:
Adam Schmideg 2019-12-12 23:38:36 +01:00 committed by Felix Lange
parent c8c6908e9a
commit 49995dc926
2 changed files with 17 additions and 2 deletions

View File

@ -9,7 +9,7 @@ before_script:
# the `install` step will run `bundle install` by default.
script:
- bundle exec jekyll build
- bundle exec htmlproofer ./_site --assume-extension --allow-hash-href
- bundle exec htmlproofer ./_site --assume-extension --allow-hash-href --empty-alt-ignore
env:
global:

View File

@ -22,5 +22,20 @@
{% for x in page.js %}{% capture target %}{% include link.html url=x %}{% endcapture %}
<script src="{{ target | strip }}"></script>
{% endfor %}
<!-- Matomo -->
<script type="text/javascript">
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/";
_paq.push(['setTrackerUrl', u+'matomo.php']);
_paq.push(['setSiteId', '22']);
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);
})();
</script>
<noscript><p><img src="https://matomo.ethereum.org/matomo.php?idsite=22&amp;rec=1" style="border:0;" alt="" /></p></noscript>
<!-- End Matomo Code -->
</head>