Skip to main content

Popup

These methods allow you to interact with the Popup (Public beta).

note

Please keep in mind that the CartPops API is subject to change. Before updating, please check the changelog to learn what has changed and whether you can safely upgrade.

show()

Open the Popup.

🛠 Method

CartPops.popup.show();

🌈 Example

jQuery( document).ready( function( $ ){
$( '#your-element' ).on( 'click' , function() {
CartPops.popup.show();
});
});

hide()

HIde the Drawer.

🛠 Method

CartPops.popup.hide();

🌈 Example

jQuery( document).ready( function( $ ){
$( '#your-element' ).on( 'click' , function() {
CartPops.popup.hide();
});
});

toggle()

Toggle the Popup.

🛠 Method

CartPops.popup.toggle();

🌈 Example

jQuery( document).ready( function( $ ){
$( '#your-element' ).on( 'click' , function() {
CartPops.popup.toggle();
});
});