Skip to content

Commit

Permalink
feat standardize script order (#974)
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmaxed authored Sep 3, 2024
1 parent 32687e8 commit 2f9cbf1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/_includes/layouts/default.njk
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@
{% endset %}
<script>{{ js | jsMin | safe }}</script>

{% if canonicalUrl | shouldCanonicalHaveGAM %}
<script src="https://securepubads.g.doubleclick.net/tag/js/gpt.js" crossorigin="anonymous" async></script>
{% endif %}

{# Dynamically load Adsense scripts #}
{% block monetization %}
{% endblock %}
Expand Down Expand Up @@ -119,9 +123,6 @@

{{ site.codeinjection_head | safe if site.codeinjection_head }}
{{ codeinjection_head | safe if codeinjection_head }}
{% if canonicalUrl | shouldCanonicalHaveGAM %}
<script async src="https://securepubads.g.doubleclick.net/tag/js/gpt.js"></script>
{% endif %}

{% block datasourceInfo %}
{% endblock %}
Expand Down

0 comments on commit 2f9cbf1

Please sign in to comment.