if (typeof dataLayer !== "undefined") {
dataLayer.push({
"ecommerce": {
"currency": "ZAR",
"impressions": [
{
"id": "37028",
"name": "Rail 9.8 XT Gen 4",
"price": "175000.0",
"brand": "Trek",
"category": "Electric mountain bikes",
"variant": "red",
"list": "CATEGORY",
"position": 1
}
,
{
"id": "41986",
"name": "Rail 9.9 X0 AXS T-Type Gen 4",
"price": "245000.0",
"brand": "Trek",
"category": "Electric mountain bikes",
"variant": "orange",
"list": "CATEGORY",
"position": 2
}
,
{
"id": "37026",
"name": "Rail 9.7 Gen 4",
"price": "120000.0",
"brand": "Trek",
"category": "Electric mountain bikes",
"variant": "reddark",
"list": "CATEGORY",
"position": 3
}
]
}
});
} else {
console.log("dataLayer");
}