-
-
Notifications
You must be signed in to change notification settings - Fork 110
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
GDPR - Add cookie consent UI #140
Conversation
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
…ser page load (consent isn't processed yet)
…hook + disable Amplitude tracking when the user is opted-out + configured cookieConsent lib
…ediately, not only on whole page refresh)
…vailable on the browser, so we use DisplayOnBrowserMount component to defer the mount for the browser only (avoid mismatch browser vs server)
7a77ea6
to
37e3f5c
Compare
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
❌ E2E tests FAILED |
…e transitions (needs full page refresh to show/hide properly)
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
✅ Deployment SUCCESS |
✅ E2E tests SUCCESS |
Demo: https://nrn-v2-mst-aptd-at-lcz-sty-c1-cookies-con.vercel.app
Allow end-users to consent (or not) to cookies.
Simple implementation based on the open-source tool "cookieconsent", only handle agree/deny/dismiss choices.
Creates a cookie to store the user's choice on the device.
When users don't consent, all analytics is disabled (Amplitude).
When users consent, their choice is stored on Amplitude, and their behavior is tracked.
Stores events for people who deny/allow, so that we can have some stats about how many agree and don't, also stores metadata associated with the consent (time, message displayed to the user)
The Amplitude cookie is not destroyed when user denies though, or it wouldn't be possible to switch on/off easily during navigation without a full page refresh, this isn't perfect according to GDPR, but I don't see how to do it better without completely disabling Amplitude when user has denied. Which would likely lead to other issues.