vue强制刷新子组件到初始状态
<edit :tableData="childData" ref="child" v-if="hackReset"></edit>
methods: { open() { this.hackReset = false this.$nextTick(() => { this.hackReset = true }) }, }
<edit :tableData="childData" ref="child" v-if="hackReset"></edit>
methods: { open() { this.hackReset = false this.$nextTick(() => { this.hackReset = true }) }, }