Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ADOP-2579] Move Dynatrace RUM to page head #1617

Merged
merged 3 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions src/main/steps/common/cookie-banner.njk
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
{% from "govuk/components/cookie-banner/macro.njk" import govukCookieBanner %}

<p hidden>Current env: {{currentEnv}} </p>

{% block head %}

{% if ['aat'].includes(currentEnv) %}
<script type="text/javascript" src="https://js-cdn.dynatrace.com/jstag/17177a07246/bf24054dsx/fb3a85222a00a995_complete.js" crossorigin="anonymous"></script>
{% elif ['prod'].includes(currentEnv) %}
<script type="text/javascript" src="https://js-cdn.dynatrace.com/jstag/17177a07246/bf00910jpo/5f55faf7cef058ac_complete.js" crossorigin="anonymous"></script>
{% endif %}

{% endblock %}

{% set html %}
<input type="hidden" name="cookie_locale" id="cookie_locale" value="{{ language }}">
<p class="govuk-body">{{cookiesLine1}}</p>
Expand Down
9 changes: 9 additions & 0 deletions src/main/steps/common/page.njk
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,15 @@
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-K66QQ98');</script>
<!-- End Google Tag Manager -->

<!-- Dynatrace RUM -->
{% if ['aat'].includes(currentEnv) %}
<script type="text/javascript" src="https://js-cdn.dynatrace.com/jstag/17177a07246/bf24054dsx/fb3a85222a00a995_complete.js" crossorigin="anonymous"></script>
{% elif ['prod'].includes(currentEnv) %}
<script type="text/javascript" src="https://js-cdn.dynatrace.com/jstag/17177a07246/bf00910jpo/5f55faf7cef058ac_complete.js" crossorigin="anonymous"></script>
{% endif %}
<!-- End Dynatrace RUM -->

{% endblock %}

{% block header %}
Expand Down