JavaScript's mouseover and mouseout events, when there are child elements inside the bound element, the mouseover and mouseout events will be triggered multiple times when
passes the bound element.
jquery solution:
jquery’s mouseenter and mouseleave methods have fixed this problem and can be directly used to replace mouseover and mouseout
But there is a mouseenter and mouseleave A small problem is that when the mouse enters the element bound to the event directly from outside the document, the mouseenter does not take effect
The temporary solution is to keep the element bound to the event away from the edge of the browser and try to leave at least 1px spacing. .
In addition, jquery’s hover() method is equivalent to using mouseenter and mouseleave. It can also solve the problems of mouseover and mouseout.