-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
BUG: gatsby-plugin-google-analytics is getting an undefined pathname #1317
Comments
Oh wow... yeah the plugin is really outdated :-( the API got updated a while ago https://www.gatsbyjs.org/docs/browser-apis/#onRouteUpdate |
could you submit a quick PR for this? I'm making a new release this afternoon so could get this out then. |
Sure thing, though I have found a secondary issue as well, you will see in PR. |
Fixed in #1318 |
This was referenced Jan 21, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Currently the code does this:
But it appears as though the parameter called
location
is structured like so:The resulting bug is that we get production code doing something like:
Causing the GA metrics to show whatever the first SSR-served landing page to be the page viewed many times over (because
page
will never change).Pretty easy change, but I am assuming this must have worked before?
Versions:
node v8.0.0
gatsby@1.0.0-beta.5
gatsby-plugin-google-analytics@1.0.0-beta.1
The text was updated successfully, but these errors were encountered: