From 7895f8905a5cb6373d46ff32b467a59e8258c033 Mon Sep 17 00:00:00 2001 From: Stanislav Lashmanov Date: Tue, 1 Jul 2025 13:58:36 +0400 Subject: [PATCH] docs: fix subscription arguments in docs (#2965) Co-authored-by: Stanislav Lashmanov --- packages/docs/core-concepts/state.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/docs/core-concepts/state.md b/packages/docs/core-concepts/state.md index 64bbae7a..a0bacc5a 100644 --- a/packages/docs/core-concepts/state.md +++ b/packages/docs/core-concepts/state.md @@ -259,7 +259,7 @@ cartStore.$subscribe((mutation, state) => { Under the hood, `$subscribe()` uses Vue's `watch()` function. You can pass the same options as you would with `watch()`. This is useful when you want to immediately trigger subscriptions after **each** state change: ```ts{4} -cartStore.$subscribe((state) => { +cartStore.$subscribe((mutation, state) => { // persist the whole state to the local storage whenever it changes localStorage.setItem('cart', JSON.stringify(state)) }, { flush: 'sync' }) -- 2.47.3