元素绑定了监听事件后,当一个指针设备(通常是鼠标)移动到这个元素上时mouseenter
事件将会被触发。
语法
element.onmouseenter = handlerFunction; var handlerFunction = element.onmouseenter;
handlerFunction
可以是 null
或者一个用于处理事件的JavaScript 函数 。
规格
规格 | 状态 | 注释 |
---|---|---|
HTML Living Standard onmouseenter |
Living Standard |
浏览器兼容性
BCD tables only load in the browser