vue子组件可以修改父组件的值吗
时间: 2023-08-30 15:08:18 浏览: 112
回答: 总所周知,Vue是不允许子组件直接修改父组件传递来的值的。Vue的父子组件之间的数据传递是单向的,父组件向子组件传递数据,子组件接收并使用这些数据,但不能直接修改父组件的值。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [Vue子组件修改父组件的传入的值](https://blog.csdn.net/weixin_47190975/article/details/126255435)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [vue中子组件更改父组件数据](https://blog.csdn.net/ct5211314/article/details/124280896)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文