错误

父组件代码:
events: {
'list-msg': msg => {
this.msg1 = msg
}
},
子组件代码:
methods: {
getRoot () {
this.$dispatch('list-msg', this.msg)
this.msg = ''
},
}
求教
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
人生最曼妙的风景,竟是内心的淡定与从容!