Skip to content

Is pinia getter appropriate as a watch target??? #2407

Closed Answered by posva
taylous asked this question in Help and Questions
Discussion options

You must be logged in to vote

it's okay to use a getter in a watcher:

watch(() => store.double, () => {})

Stores are reactive objects, so using a function is needed

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@taylous
Comment options

Answer selected by taylous
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants