Expand my Community achievements bar.

SOLVED

Question on ACDL vs direct calll rules

Avatar

Level 2

I have a Adobe Client Data Layer implemented and somehow I am not able to read the data Layer push events since it is a single page application, meaning the page does not load but only the URL changes.

When I use direct call rule then it works fine. So, I have told my developer to change it as shown below

 

Currently Implemented

window.adobeDataLayer.push({
    "event": "filterTest",
    "filter": [{
        activeFilterList: "list of filters by the user in colon delimited format",
        activeFiltersClicked: [
            {
                itemName: "brand",
                itemValues: ["Altra", "Avia"],
            },
                  ]
    }]
});

 

Expected Implementation

 

_satellite.track(
    "filterTest",
    {
        activeFilterList: "list of filters by the user in colon delimited format",
        activeFiltersClicked: [
            {
                itemName: "brand",
                itemValues: ["Altra", "Avia"],
            },
            
        ]
    }
);

 

Does above logic look good to you? Any other approaches which I can use?

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

What do you mean that you can't read the data layer push events because it's a single page application... reading a push event is not dependent on a page loading.... Event based data layers are designed to work with both traditional and SPA implementations.

 

I assume that you are trying to use "Window Loaded" or "DOM Ready" as your trigger... which does look at pages being loaded, and if so, that is your issue... not the data layer. In an event based data layer, that isn't the trigger you should be using... you should create a trigger based on "Adobe Client Data Layer" and "Data Pushed"

 

Jennifer_Dungan_1-1680458507265.png

 

 

This way, ANY events can be pushed (page views, clicks, form completes, etc) and you have the control over how each of those track by listening for the specific event.

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor

What do you mean that you can't read the data layer push events because it's a single page application... reading a push event is not dependent on a page loading.... Event based data layers are designed to work with both traditional and SPA implementations.

 

I assume that you are trying to use "Window Loaded" or "DOM Ready" as your trigger... which does look at pages being loaded, and if so, that is your issue... not the data layer. In an event based data layer, that isn't the trigger you should be using... you should create a trigger based on "Adobe Client Data Layer" and "Data Pushed"

 

Jennifer_Dungan_1-1680458507265.png

 

 

This way, ANY events can be pushed (page views, clicks, form completes, etc) and you have the control over how each of those track by listening for the specific event.