Skip to main content
All CollectionsAdvancedJavascript
Before-tab-display Event
Before-tab-display Event
Updated over 2 months ago

The before-tab-display event is fired before the display of a tab. This is one of the various events Wisepops can trigger as part of our JS callbacks feature.
โ€‹

Prevent tab display

The display of the tab can be prevented by calling preventDefault() on the event:

wisepops('listen', 'before-tab-display', function(event) {
event.preventDefault();
});

Event target

The targeted element (event.target) is the tab HTML element, with the class wisepops-tab.

Did this answer your question?