]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Docs: Only include Plausible for html, not for epub etc (#107637)
authorHugo van Kemenade <hugovk@users.noreply.github.com>
Fri, 4 Aug 2023 18:33:34 +0000 (21:33 +0300)
committerGitHub <noreply@github.com>
Fri, 4 Aug 2023 18:33:34 +0000 (21:33 +0300)
Only include Plausible for html, not for epub etc

Doc/tools/templates/layout.html

index 9832feba141675113edb824bef8464272a2878ec..80103158ea01e63cfa7d531c7ad16ee3cb13588b 100644 (file)
@@ -26,7 +26,9 @@
 {% endblock %}
 
 {% block extrahead %}
-    <script defer data-domain="docs.python.org" src="https://plausible.io/js/script.js"></script>
+    {% if builder == "html" %}
+      <script defer data-domain="docs.python.org" src="https://plausible.io/js/script.js"></script>
+    {% endif %}
     <link rel="canonical" href="https://docs.python.org/3/{{pagename}}.html" />
     {% if builder != "htmlhelp" %}
       {% if pagename == 'whatsnew/changelog' and not embedded %}