8.SET Flat
Simple version of 8.SET Compose with limited user interaction - for example for a cart layer
8.SET Flat on a cart layer modal
8.SET Flat on a cart layer offcanvas

Widget-Element

Show matching product set for a given SKU or Main-SKU
1
<div data-8select-widget-id="8.SET-Flat" data-sku="42"></div>
Copied!
  • data-sku is a dynamic attribute
The 8SELECT integration team will adjust the widget styling 🎨 to your shop design. ❤️

Dynamic widget

You can add the 8.SET Flat widget to the DOM before your modal is even shown or you can add it when your modal is shown. To save requests and bandwidth for your users, you should only add the widget when it is actually on the viewport. The 8.SDK is probably already loaded by then, so you need to call window._8select.initCSE() to notify the 8.SDK about the new widget.
To also be on the safe side in case something went wrong when loading our SDK you probably should do something like this:
1
if (window._8select && typeof window._8select.initCSE === 'function') {
2
window._8select.initCSE();
3
}
Copied!
The 8.SDK is probably already loaded when you add 8.SET Flat, so you need to call window._8select.initCSE()to notify the 8.SDK about the new widget.