Hi, I am using adobeDataLayer and pushing events to it. However, I noticed that as I move across the pages, events are being passed multiple times along with other page details when pushing data into adobeDataLayer. This becomes a problem that it's hard to locate the events, is this normal behavior? If not, what should I do to solve this issue?
Any insights would be greatly appreciated!
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
So I guessed your site is a SPA such that the same window.adobeDataLayer being used for multiple "pages", as the Adobe extension does not carry adobeDataLayer forward from page to page by itself.
For SPA and when the adobeDataLayer is growing too long, you can use the reset data layer action to compute and merge all items in the data layer into one.
So I guessed your site is a SPA such that the same window.adobeDataLayer being used for multiple "pages", as the Adobe extension does not carry adobeDataLayer forward from page to page by itself.
For SPA and when the adobeDataLayer is growing too long, you can use the reset data layer action to compute and merge all items in the data layer into one.
Hi Leo, thanks for helping! I have tried to use the reset data layer action, but after that I cannot get any data from adobeDataLayer.
Views
Replies
Total Likes
I just performed a test on the reset action and it works as expected. In your case the disappearing of the adobeDataLayer, you need to check if there are any other codes in Launch, or if your website manipulated the adobeDataLayer and accidentally deleted it.
Thanks Leo!
Views
Replies
Total Likes
Don't inspect the adobeDataLayer array directly. Instead, log adobeDataLayer.getState() to see the latest, computed state of the data layer when each event occurs.
Thanks Yuhui!
Views
Replies
Total Likes
Hi @YZ_J , I am also having the same issue, can you help to share the solution that worked for you.
Views
Replies
Total Likes
Views
Like
Replies
Views
Likes
Replies