通过调度操作在Vue beforeEach挂钩和存储中获取数据

时间:2017-12-15 04:20:28

标签: javascript asynchronous vue.js frontend

我通过调度动作在storeAach挂钩中保存数据fecthing。然后我想在组件中使用它们。我感到困惑的是,有时组件是在执行该操作之前创建的,这导致我丢失这些数据并在下面出现错误。

dispatching action in beforeEnter

enter image description here

enter image description here

enter image description here

enter image description here

0 个答案:

没有答案