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

Feature request: impressionTracker track after X seconds of visibility #244

Open
shocknawe opened this issue Jun 4, 2019 · 0 comments
Open

Comments

@shocknawe
Copy link

Feature request: impressionTracker tracking after X seconds of element visibility

It would be nice to know if the user has spent enough time within the element to read it before tracking it as an impression. I was thinking the user needs somewhere around 2-3 seconds to properly be 'impressed' by an element

sample use case:

// JAVASCRIPT
ga('impressionTracker:observeElements', ['product-description']);

// HTML
<div id="product-description"
  data-ga-event-min-duration="3000"
  data-ga-event-category="Product Page"
  data-ga-event-action="Read Product Description"
  data-ga-event-label="Fender FA-345CE Auditorium Acoustic Guitar, Tea Burst">
  <p>An instrument that sounds as good as it looks ...</p>
</div>

sample element visibility duration tracking:
https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API/Timing_element_visibility#Result

image
screenshot of 15 seconds of impression

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant