Skip to content

Instantly share code, notes, and snippets.

@jason-enstedt
Created March 10, 2020 00:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jason-enstedt/638fae3da7bb48c79e453732f597de61 to your computer and use it in GitHub Desktop.
Save jason-enstedt/638fae3da7bb48c79e453732f597de61 to your computer and use it in GitHub Desktop.
simple jquery for mouse enter and leave pop up cart
var cartbtn = $('.shop-btn');
var popup = $('.popout');
cartbtn.on('mouseenter', function(){
body.classList.add('cartShow');
});
popup.on('mouseleave', function(){
body.classList.remove('cartShow');
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment