code: function (el, e) {
  
  		var related = e.relatedTarget;
  
  		if (!related) { return true; }
  
  		try {
  			while (related && (related !== el)) {
  				related = related.parentNode;
  			}
  		} catch (err) {
  			return false;
  		}
  		return (related !== el);
  	}
docs: check if element really left/entered the event target (for mouseenter/mouseleave)