if (typeof dataLayer !== "undefined") {
dataLayer.push({
"ecommerce": {
"currency": "AUD",
"impressions": [
{
"id": "41712",
"name": "Marlin+ 8",
"price": "5399.99",
"brand": "Trek",
"category": "Electric mountain bikes",
"variant": "purple_black",
"list": "CATEGORY",
"position": 1
}
,
{
"id": "41017",
"name": "Marlin+ 6",
"price": "4299.99",
"brand": "Trek",
"category": "Electric mountain bikes",
"variant": "red",
"list": "CATEGORY",
"position": 2
}
]
}
});
} else {
console.log("dataLayer");
}