(vue.js)cannot read property ‘commit’of undefined

问题: (vue.js)cannot read property ‘commit’of undefined
描述:

我的分组都分好了,但是vueX有点迷茫怎么用 看图

(vue.js)cannot read property ‘commit’of undefined

(vue.js)cannot read property ‘commit’of undefined

(vue.js)cannot read property ‘commit’of undefined

(vue.js)cannot read property ‘commit’of undefined

(vue.js)cannot read property ‘commit’of undefined

求大神给点意见或建议


解决方案1:

Vue里面store未注册!!!!!!!!!!!!!!!!!!!

解决方案2:

commit在哪里啊。。。vuex修改状态的流程一般为dispatch-->commit-->mutations,异步的话还要在commit前加actions。

解决方案3:

(vue.js)cannot read property ‘commit’of undefined
这里有个import,你看看你引了没

解决方案4:

this.$store.commit(types.ADD_BIAOTI, this.titler)


以上介绍了“ (vue.js)cannot read property ‘commit’of undefined”的问题解答,希望对有需要的网友有所帮助。
本文网址链接:http://www.codes51.com/itwd/4517864.html