bedrock icon indicating copy to clipboard operation
bedrock copied to clipboard

Add analytics to the language switcher

Open craigcook opened this issue 8 years ago • 3 comments

We're curious how many people use the language switcher in the footer to change to a language other than what we initially serve them. Having some data on this would inform a proposed redesign of our language switcher. It seems like something we could do pretty easily with GA and an event on the switcher dropdown?

craigcook avatar Jun 08 '18 22:06 craigcook

... we could do pretty easily with GA and an event on the switcher ...

To implement this, would we use dataLayer.push()?

zehcnas34 avatar Jun 10 '18 21:06 zehcnas34

It looks like we already capture this data in GA: https://github.com/mozilla/bedrock/blob/master/media/js/base/mozilla-utils.js#L52

alexgibson avatar Jun 10 '18 21:06 alexgibson

It looks like we already capture this data in GA

Ah! So we do. I don't know why it didn't occur to me to check first before I assumed we didn't.

craigcook avatar Jun 10 '18 23:06 craigcook