Answer can be in vanilla js or jQuery. I want to hide a div with the id \"myDiv\" if the user is no longer hovering over a link with the id \"myLink\" or a span with the id
You could use a multiple selector:
$("#someElement, #someOtherElement").mouseleave(function() { // Do something. });