vue.js如何实现移入移出效果

 455已收录

vue.js实现移入移出效果的方法:【methods:{enter(index){this.seen = true;this.current = index;},leave(){this.seen = false;this.cur...】。


vue.js如何实现移入移出效果


vue.js实现移入移出事件的具体代码:

html代码:

<i class="icon" @mouseenter="enter(index)" @mouseleave="leave()"></i>

逻辑代码:

methods:{
    enter(index){
        this.seen = true;
        this.current = index;
    },
    leave(){
        this.seen = false;
        this.current = null;
    }
}


TAG标签: vue.js移入移出
本文网址:https://www.3ka.cn/server-3482.html
转载请声明来自:汇云资源网 - vue.js如何实现移入移出效果

评论(0)条

您还没有登录,请 登录 后发表评论!

提示:请勿发布广告垃圾评论,否则封号处理!!

    猜你喜欢