I have been looking for guidance and cannot find any. I currently track items viewed within item lists using the view_item_list event for enhanced ecommerce that includes product information for all products in the list. On selection of a product I track a select_item event which has specific product data tied to the item list data they clicked on the product from.
All of that works. From the product details page an view_item event is fired. This page is also the only page that an add_to_cart event can happen. I currently track add_to_cart but do not include any item list information in the add to cart.
I am looking for best practices for if item list data should only be passed to an add_to_cart event if that list actually supports an add to cart action, or if I should be passing it because the traffic to the product for that user came from the an item list.
The Item Lists report in GA4 is pretty useless without add to cart/checkouts/purchases within it but I haven't seen any documentation to tell me I need to pass it along. Similarly, with this report do I also need to store internally the source of the add to carts to pass over to GA4 for checkouts and purchases so each item in a purchase can be tied back to where that add to cart came from?
I would say that in your scenario you're correct in what you're doing. On the website I run, customers are able to add/remove to cart from both the category & search listings and the product details page. On the category/search listing I pass
item_list_idanditem_list_name, but on the product details page I don't. I also don't pass this when modifying a product from the cart listing (though I do pass aview_cartevent).GA knows the url of the page that triggers all events, so I don't think you should need to store that.