Skip to content

Commit b5dfbd9

Browse files
committed
修正mutation内操作state的行为
没记错的话,state应该是整个state
1 parent 2f59a23 commit b5dfbd9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/zh-cn/actions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const store = new Vuex.Store({
1919
},
2020
mutations: {
2121
INCREMENT (state, x) {
22-
state += x
22+
state.count += x
2323
}
2424
},
2525
actions: {

0 commit comments

Comments
 (0)