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

fix/window.gtag is not defined for Next.js-hydration event(#40410) #40645

Merged
merged 7 commits into from Sep 23, 2022
Merged

fix/window.gtag is not defined for Next.js-hydration event(#40410) #40645

merged 7 commits into from Sep 23, 2022

Conversation

dave-hay
Copy link
Contributor

@dave-hay dave-hay commented Sep 18, 2022

Next.js-hydration now triggered after gtag is initialized. Fixed by adding _document.js and appropriate script elements.

Documentation / Examples

Next.js-hydration now triggered after gtag is initialized.

<!--
## Documentation / Examples

- [X] Related issues linked using fixes #40410
- [X] Make sure the linting passes by running `pnpm lint`
- [X] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)

Next.js-hydration now triggered after gtag is initialized.
-->
@ijjk ijjk added the examples Issue/PR related to examples label Sep 18, 2022
Co-authored-by: Sukka <isukkaw@gmail.com>
Co-authored-by: Sukka <isukkaw@gmail.com>
Copy link
Member

@ijjk ijjk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@kodiakhq kodiakhq bot merged commit bebf372 into vercel:canary Sep 23, 2022
@dave-hay dave-hay deleted the fix/issue-#40410 branch September 23, 2022 01:32
@dave-hay dave-hay restored the fix/issue-#40410 branch September 23, 2022 01:34
@dave-hay dave-hay deleted the fix/issue-#40410 branch September 23, 2022 01:39
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
examples Issue/PR related to examples
Projects
None yet
Development

Successfully merging this pull request may close these issues.

window.gtag is not defined for Next.js-hydration event
3 participants