From 0334aab17b951d9346276963c13c8974f45e6950 Mon Sep 17 00:00:00 2001 From: Li Kui <90845831+likui628@users.noreply.github.com> Date: Thu, 7 Oct 2021 08:53:24 +0800 Subject: [PATCH] docs: increment argument 'value' need default value (#995) --- docs/guide/advanced/vuex.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/guide/advanced/vuex.md b/docs/guide/advanced/vuex.md index 83c7dca0e..531ca22a2 100644 --- a/docs/guide/advanced/vuex.md +++ b/docs/guide/advanced/vuex.md @@ -158,7 +158,7 @@ const createVuexStore = (initialState) => ...initialState }, mutations: { - increment(state, value) { + increment(state, value = 1) { state.count += value } }