Skip to main content

AddToWishlistProductPageWidget

This widget allows users to add or remove the current product and its variant to or from their wishlist on product pages.

Widget example

Add

Add to wishlist widget example

Remove

Remove from wishlist widget example

Code

<div
class="gw-wl-add-to-wishlist-placeholder"
data-gw-product-id="1234567890"
data-gw-variant-id="1234567890"
data-gw-button-class="custom-class-name"
style="display: block"
></div>

Attributes

Attributes
data-gw-product-idrequired
Specifies the unique identifier for the product to be added or removed from the wishlist.
data-gw-variant-idrequired
Specifies the unique identifier for the product variant to be added or removed from the wishlist.
data-gw-button-class?optional
Specifies the custom class name for the button.