diff --git a/packages/docs/zh/cookbook/migration-vuex.md b/packages/docs/zh/cookbook/migration-vuex.md index 2ae236f4d..c29956118 100644 --- a/packages/docs/zh/cookbook/migration-vuex.md +++ b/packages/docs/zh/cookbook/migration-vuex.md @@ -164,7 +164,7 @@ export const useAuthUserStore = defineStore('auth/user', { this.lastName = payload.lastName this.userId = payload.userId }, - // easily reset state using `$reset` + // 使用 `$reset` 可以轻松重置 state clearUser () { this.$reset() } diff --git a/packages/docs/zh/core-concepts/actions.md b/packages/docs/zh/core-concepts/actions.md index b930e43f4..e521dd644 100644 --- a/packages/docs/zh/core-concepts/actions.md +++ b/packages/docs/zh/core-concepts/actions.md @@ -58,11 +58,11 @@ Action 可以像函数或者通常意义上的方法一样被调用: ```vue ``` @@ -208,7 +208,7 @@ unsubscribe() ```vue ``` diff --git a/packages/docs/zh/core-concepts/getters.md b/packages/docs/zh/core-concepts/getters.md index 97e52affa..4ac6ba68a 100644 --- a/packages/docs/zh/core-concepts/getters.md +++ b/packages/docs/zh/core-concepts/getters.md @@ -99,8 +99,8 @@ export const useStore = defineStore('main', { import { useUserListStore } from './store' const userList = useUserListStore() const { getUserById } = storeToRefs(userList) -// note you will have to use `getUserById.value` to access -// the function within the