- 博客(1)
- 收藏
- 关注
原创 vuex报错unknown mutation type:
原始代码错误原因:mutations中的increment用的小写,Vue建议用大写解决方法:increment改成INCREMENT就可以了const store = new Vuex.Store({ state: { counter: 1000 }, mutations: { //方法 increment(state) { state.counter++ },})} <div id="app"> ..
2021-04-22 10:38:53
2250
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人