[vuex]Cannot read property 'dispatch' of undefined

vuex访问报错:
[Vue warn]: Error in created hook: "TypeError: Cannot read property 'dispatch' of undefined"
found in


源代码:

解决:
不能用有箭头方法,参考文档。

你可能感兴趣的:([vuex]Cannot read property 'dispatch' of undefined)