Skip to content

Commit

Permalink
add yandex and google metrics to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Deys Timofey committed Oct 19, 2023
1 parent 5b25aa2 commit 09c87ba
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
Empty file added docs/assets/js/yametrics.js.py
Empty file.
27 changes: 27 additions & 0 deletions docs/partials/integrations/analytics/custom.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-46XYNH0Q80"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'G-46XYNH0Q80');
</script>

<!-- Yandex.Metrika counter -->
<script type="text/javascript" >
(function(m,e,t,r,i,k,a){m[i]=m[i]||function(){(m[i].a=m[i].a||[]).push(arguments)};
m[i].l=1*new Date();
for (var j = 0; j < document.scripts.length; j++) {if (document.scripts[j].src === r) { return; }}
k=e.createElement(t),a=e.getElementsByTagName(t)[0],k.async=1,k.src=r,a.parentNode.insertBefore(k,a)})
(window, document, "script", "https://mc.yandex.ru/metrika/tag.js", "ym");

ym(95307533, "init", {
clickmap:true,
trackLinks:true,
accurateTrackBounce:true,
webvisor:true
});
</script>
<noscript><div><img src="https://mc.yandex.ru/watch/95307533" style="position:absolute; left:-9999px;" alt="" /></div></noscript>
<!-- /Yandex.Metrika counter -->
3 changes: 3 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ repo_name: PyMLup
theme:
name: material
language: en
custom_dir: docs
features:
- navigation.tracking
- search.suggest
Expand Down Expand Up @@ -34,6 +35,8 @@ theme:

extra:
homepage: https://mlup.org
analytics:
provider: custom
version:
provider: mike
default: stable

0 comments on commit 09c87ba

Please sign in to comment.