import clickoutside from 'element-ui/src/utils/clickoutside'
export default {
directives: { clickoutside},
data: function() {
return {
}
}
}
<div v-clickoutside="handleClickOutside"></div>
methods: {
// 点击区域外
handleClickOutside() {}
}
【element-ui中的clickoutside 指令 点击元素外触发】
最新推荐文章于 2024-07-19 14:23:33 发布