adobe / aem-core-wcm-components

Standardized components to build websites with AEM.
https://docs.adobe.com/content/help/en/experience-manager-core-components/using/introduction.html
Apache License 2.0
733 stars 741 forks source link

[DataLayer] Trigger an event when the visitor has viewed a component #1042

Open jckautzmann opened 4 years ago

jckautzmann commented 4 years ago

When a visitor requests a page, the data layer should trigger a cmp:show event for all the components that are within the page viewport. The behavior should be the same when the visitor scrolls the page. If a component is viewed again, it shouldn't re-trigger the event.

jckautzmann commented 4 years ago

Proof of concept available at: https://github.com/adobe/aem-core-wcm-components/tree/feature/datalayer-viewed-components