question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How can I set window['ga-disable-UA-XXXX-XX'] to true initially

See original GitHub issue

I’d like to implement an Opt-In component in my nuxt app to actively opt into Google Analytics Tracking (due to European DSGVO regulation). Is there a way to set window['ga-disable-UA-XXXX-XX'] = true initially to prevent gtag() to start tracking?

Only when the user hits an agree-button the i’d like to set window['ga-disable-UA-XXXX-XX'] = false programmatically in my Nuxt-component. Is that possible, too?

Thanks for helping out.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:2
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

13reactions
itproprocommented, Mar 23, 2020

This is the most important functionality, otherwise no one can use this module on their website without being sued (in worst case). Even, if you ask people for their consent, you are not allowed to enable any analytics or tracking before the user has actually clicked yes. Otherwise it would be a violation of EU ePrivacy directive, GDPR or both. This applies to all websites, no matter where they are hosted, as long as european citizens are part of the target group of that website. It would be great, if someone could answer how this kind of behavior can be configured using this nuxt module. If it’s not possible I have to use gtag natively and use the provided window['ga-disable-GA_MEASUREMENT_ID'] = true; method.

3reactions
Snake231088commented, Apr 9, 2021

Any update?

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to set a default value on a Boolean in a Code First model?
Another option is create a default constructor and set the properties with the default values you need: public class Revision { public Boolean...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found