Übersicht
if (typeof dataLayer !== "undefined") {
dataLayer.push({
"ecommerce": {
"currency": "CHF",
"impressions": [
{
"id": "36287",
"name": "Trek Patch Trucker Hat",
"price": "35.0",
"brand": "Trek",
"category": "Casual caps & hats",
"variant": "black",
"list": "More Options",
"position": 1
}
,
{
"id": "40642",
"name": "Trek Bicycle Co 5 Panel Hat",
"price": "28.0",
"brand": "Trek",
"category": "Casual caps & hats",
"variant": "orange",
"list": "More Options",
"position": 2
}
,
{
"id": "34748",
"name": "Trek Red Patch Beanie",
"price": "28.0",
"brand": "Trek",
"category": "Cycling caps & headwear",
"variant": "greydark",
"list": "More Options",
"position": 3
}
,
{
"id": "37339",
"name": "Trek Circle Beanie",
"price": "25.0",
"brand": "Trek",
"category": "Casual caps & hats",
"variant": "grey",
"list": "More Options",
"position": 4
}
,
{
"id": "45021",
"name": "100% Trek Factory Racing 5-Panel Cap",
"price": "39.0",
"brand": "100%",
"category": "Casual caps & hats",
"variant": "black",
"list": "More Options",
"position": 5
}
,
{
"id": "35308",
"name": "Santini Trek-Segafredo Team Podium-Cap",
"price": "35.0",
"brand": "Santini",
"category": "Casual caps & hats",
"variant": "bluedark_white",
"list": "More Options",
"position": 6
}
,
{
"id": "45022",
"name": "100% Trek Factory Racing Pom Beanie",
"price": "35.0",
"brand": "100%",
"category": "Casual caps & hats",
"variant": "black",
"list": "More Options",
"position": 7
}
]
}
});
} else {
console.log("dataLayer");
}