Repository navigation
Load the GA script from the hub stream's Google tag - #72
Merged
Merged
Conversation
Google returns 404 for gtag/js with the hub's measurement ID, so the script never loaded and the hub has sent nothing since it moved to its own property. The stream's Google tag is the web book's tag ID; loading the script from it and configuring only the hub's ID delivers events to the hub property, confirmed in its realtime report.
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.
The hub has not sent anything to GA4 since #63. This fixes it.
What was wrong
ga.jsloadshttps://www.googletagmanager.com/gtag/js?id=G-C5V0X2SGD3.G-C5V0X2SGD3G-BEBVKYH8HL, the same tag the web book usesThe change
G-BEBVKYH8HL.G-C5V0X2SGD3is configured, so the hub's page views andhubTrackevents go to the hub's property and nowhere else.Checked
I loaded the script this way on the live hub in a real Chrome and sent a test event (
ga_check2). It showed up in the hub property's realtime report within a minute.The same report also shows page views from the web book: the shared Google tag sends web book traffic to this property too. That is unrelated to this change.
Generated by Claude Code