if (typeof dataLayer !== "undefined") {
dataLayer.push({
"ecommerce": {
"currency": "USD",
"impressions": [
{
"id": "46146",
"name": "Top Fuel 9.9 XX AXS Gen 4",
"price": "13599.99",
"brand": "Trek",
"category": "Trail mountain bikes",
"variant": "purpledark",
"list": "CATEGORY",
"position": 1
}
,
{
"id": "46145",
"name": "Top Fuel 9.9 X0 AXS Gen 4",
"price": "10999.99",
"brand": "Trek",
"category": "Trail mountain bikes",
"variant": "purpledark",
"list": "CATEGORY",
"position": 2
}
,
{
"id": "46161",
"name": "Top Fuel 9.8 XT Gen 4",
"price": "8749.99",
"brand": "Trek",
"category": "Trail mountain bikes",
"variant": "purpledark",
"list": "CATEGORY",
"position": 3
}
,
{
"id": "35178",
"name": "Top Fuel 9.7 Gen 3",
"price": "3989.99",
"brand": "Trek",
"category": "Trail mountain bikes",
"variant": "bluedark_blue",
"list": "CATEGORY",
"position": 4
}
,
{
"id": "35070",
"name": "Top Fuel 7 Gen 3",
"price": "3819.99",
"brand": "Trek",
"category": "Trail mountain bikes",
"variant": "red",
"list": "CATEGORY",
"position": 5
}
]
}
});
} else {
console.log("dataLayer");
}