In vue, the parent component nests the child component, and how the child component passes the value to the parent component

the screenshot of the application is a child component, and the preservation of my parent component requires the value of the child component. Since there are forms that need to be edited in my view, the save button is in the parent component

Mar.20,2021

this generally has two ideas

  1. the child component emit event to the parent component, taking the value up
  2. use a state container such as vuex
Menu