赞
踩
1.两种绑定方式
<div v-on:mouseover="handleOver($event)" v-on:mouseout="handleOut($event)"></div> <div @mouseover="mouseOver" @mouseleave="mouseLeave"></div> handleOver (e) { console.log('移入:', e); e.currentTarget.className = "xxx"; }, handleOut (e) { console.log('移出:', e); e.currentTarget.className = "yyy"; }, mouseOver () {}, mouseLeave () {}
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。