vue弹出框每次打开重新初始化
时间:2020-07-17 15:14:05
收藏:0
阅读:985
在网上找到两种方法,
一种是绑定时间戳:
<el-dialog :key="timer" > </el-dialog>
this.timer = new Date().getTime() // 每次打开模态框传入新的时间戳 ,就会刷新了
但是尝试之后发现每次屏幕会闪一下,
于是用了另一种方法:
将 :visible.sync 与 v-if 同时使用
原文:https://www.cnblogs.com/yangyuzhuo/p/13329404.html
评论(0)