The mouseover and mouseout events are triggered multiple times by binding elements, and there's a good workaround for this problem.
The mouseover and Mouseout events of JavaScript, where there are child elements within the binding element,
The mouseover and mouseout events are triggered multiple times by binding elements.
jquery Solution:
The MouseEnter and MouseLeave methods of jquery have fixed this problem and can be used directly to replace MouseOver and mouseout
But there's a little problem with MouseEnter and MouseLeave. When you let the mouse enter the element that binds the event directly from outside the document, the MouseEnter does not take effect
The temporary solution is to not allow the elements of the binding event to be on the edge of the browser, leaving at least 1px of space.
In addition, the hover () method of jquery is equivalent to the use of MouseEnter and MouseLeave. can also solve the problems of mouseover and mouseout.