-
Notifications
You must be signed in to change notification settings - Fork 7
[PP-7355] Add usage tracking via Google Analytics 4 #204
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
Draft
yndajas
wants to merge
3
commits into
main
Choose a base branch
from
ga4-tracking
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+24
−11
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This brings in support for using Google Tag Manager for Google Analytics 4
This config setting is used by the tech docs gem to add GA4 usage tracking via the Google Tag Manager approach when users consent
This isn't Content API - it's documentation for Content API. The new cookie banner would read "Cookies on Content API" without this change, which is a little confusing
dad470a to
6a34d48
Compare
yndajas
added a commit
to alphagov/govuk-infrastructure
that referenced
this pull request
Nov 19, 2025
The CodeQL action decides which languages to analyse based on the file extensions present in a repo. However, if it analyses a language and finds no analysable code, it will error https://docs.github.com/en/code-security/code-scanning/troubleshooting-code-scanning/no-source-code-seen-during-build This change will allow us to specify which languages should be analysed so that we can exclude a language for which there's no analysable code This does mean that if analysable code is later added to a repo where its language has been ignored, we wouldn't be analysing it. That doesn't feel great, but this seems to be a limitation of CodeQL The following PR exhibited this error: alphagov/govuk-content-api-docs#204. We have .js files in that repo but they only contain (magic) comments. This wasn't an issue with older versions of CodeQL. We're currently using 2.23.5 - the last merged PR used 2.23.2 and passed the CodeQL checks: alphagov/govuk-content-api-docs#203
yndajas
added a commit
to alphagov/govuk-infrastructure
that referenced
this pull request
Nov 19, 2025
The CodeQL action decides which languages to analyse based on the file extensions present in a repo. However, if it analyses a language and finds no analysable code, it will error https://docs.github.com/en/code-security/code-scanning/troubleshooting-code-scanning/no-source-code-seen-during-build This change will allow us to specify which languages should be analysed so that we can exclude a language for which there's no analysable code https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning#changing-the-languages-that-are-analyzed This does mean that if analysable code is later added to a repo where its language has been ignored, we wouldn't be analysing it. That doesn't feel great, but this seems to be a limitation of CodeQL The following PR exhibited this error: alphagov/govuk-content-api-docs#204. We have .js files in that repo but they only contain (magic) comments. This wasn't an issue with older versions of CodeQL. We're currently using 2.23.5 - the last merged PR used 2.23.2 and passed the CodeQL checks: alphagov/govuk-content-api-docs#203
yndajas
added a commit
to alphagov/govuk-infrastructure
that referenced
this pull request
Nov 19, 2025
The CodeQL action decides which languages to analyse based on the file extensions present in a repo. However, if it finds no analysable code for one of those languages, it will error https://docs.github.com/en/code-security/code-scanning/troubleshooting-code-scanning/no-source-code-seen-during-build This change will allow us to specify which languages should be analysed so that we can exclude a language for which there's no analysable code https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning#changing-the-languages-that-are-analyzed This does mean that if analysable code is later added to a repo where its language has been ignored, we wouldn't be analysing it. That doesn't feel great, but this seems to be a limitation of CodeQL The following PR exhibited this error: alphagov/govuk-content-api-docs#204. We have .js files in that repo but they only contain (magic) comments. This wasn't an issue with older versions of CodeQL. We're currently using 2.23.5 - the last merged PR used 2.23.2 and passed the CodeQL checks: alphagov/govuk-content-api-docs#203
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We want to know how much traffic these docs get