Darstellung
Feature: GA4 Website Tracking
Summary
- Das Marketing-Frontend von Work7 laedt GA4 global ueber das Root-Layout.
- Die Measurement ID wird ueber
NEXT_PUBLIC_GA_MEASUREMENT_IDkonfiguriert. - Erfolg:
gtag.jswird nur bei gesetzter Env geladen und sendetconfigfuerG-QLCNYQ52KP.
Scope
- In Scope:
- Root-Layout um GA4-Script-Load erweitern
- Deploy-Values (dev/test/prod) um die Env-Variable erweitern
- Lokale Env auf neue Variable umstellen
- Out of Scope:
- Event-Tracking pro Feature (z. B. CTA-Clicks)
- Consent-Management im Work7-Produkt
Key Changes
- UI / User Flow:
- Keine sichtbare UI-Aenderung.
- Backend / Logik:
- Script-Injektion im Next.js Layout via
next/script.
- Script-Injektion im Next.js Layout via
- Config / ENV:
NEXT_PUBLIC_GA_MEASUREMENT_ID=G-QLCNYQ52KP.
- Dokumentation:
- Feature-Spec in
docs/features/.
- Feature-Spec in
Akzeptanzkriterien
- [ ] GA4-Script wird im Browser geladen, wenn
NEXT_PUBLIC_GA_MEASUREMENT_IDgesetzt ist 📅 2026-06-08 - [ ] Ohne Env-Variable wird kein GA4-Script gerendert 📅 2026-06-08
- [ ] Deploy-Konfigurationen enthalten die neue Variable in dev/test/prod 📅 2026-06-08
Links
- Implementierung:
src/apps/landing/src/app/layout.tsx - Deploy:
src/deploy/values-dev-landing.yaml,src/deploy/values-test-landing.yaml,src/deploy/values-prod-landing.yaml