Skip to content

showBaseConsents

showBaseConsents is a DOM event that occurs whenever the basic consents modal is displayed.

Event body

none

Example

In this example we listen to showBaseConsents event and perform an action whenever it's emitted.

useStorefront(async (storefront) => {
    document.addEventListener('showBaseConsents', () => {
        console.log('Basic consents modal has been displayed');
    });
});