docs: load analytics and marketing tags only after cookie consent - #16088
Merged
devGregA merged 1 commit intoSep 25, 2026
Merged
Conversation
The docs site loaded the Reo and Apollo trackers for every visitor with no consent prompt. It now loads HubSpot's cookie banner (the portal already has an opt-in policy for docs.defectdojo.com) and waits for the visitor's choice before loading anything else: - Google Consent Mode v2 defaults to denied. - GA4 and the defectdojo.com tag container load on accept, matching defectdojo.com. Apollo now comes from that container, and Reo loads with it. - Withdrawing consent clears the tags' first-party cookies and reloads the page. Reo cookies left by the old ungated tag are removed for visitors who have not consented. - The footer gains "Privacy policy" and "Cookie settings" links in all eight languages. Cookie settings reopens the banner. - Development builds (hugo server) load no tags at all. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
devGregA
enabled auto-merge
September 25, 2026 04:17
devGregA
disabled auto-merge
September 25, 2026 04:39
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
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.
Summary
docs.defectdojo.com loaded the Reo and Apollo trackers for every visitor without asking. This change puts every analytics and marketing tag on the docs behind cookie consent, the same way defectdojo.com already works.
hugo serverbuilds load no tags at all, so local previews never send analytics.Tested against a production build served locally. Before consent and after decline, no third-party requests or cookies. After accept, the expected tags load. After withdrawal, cookies are cleared and nothing loads after the reload.
🤖 Generated with Claude Code