two common components in an interface need to communicate with each other. Bus"s method is adopted, but it is found that it does not trigger
for the first time.components that pass data (component 1):
():
[Operation flow]: modify the information in the input of component 1, and @ change triggers the bus to send data; click the button in component 2 to receive the data sent by bus, and store the data in the database.
[question]: how to solve the problem that I didn"t receive the data sent by bus when I clicked the save button for the first time?
[description]: I have found a lot of methods on Baidu, saying that bus is triggered to send data in the beforeDestory of component one, but in this case, I have to close this interface every time to get the data, which does not meet my needs at all.
Gods, may I ask how to solve this problem?