graycoreio/daffodil

View on GitHub
libs/analytics-provider-data-layer/src/lib/layers/ecommerce/cart-pageview.ts

Summary

Maintainability
A
0 mins
Test Coverage
import { DataLayerProduct } from './product/product';

interface DaffDataLayerCartProduct extends DataLayerProduct {
  quantity: number;
}

// TODO: this isn't a true data layer type. Where should it actually reside?
export interface DaffDataLayerCartPageView {
  event: 'viewCart';
  ecommerce: {
    cart: {
      items: DaffDataLayerCartProduct[];
    };
  };
}