Add example for $watch'ing $store to docs. #1546
james0r
started this conversation in
3. Feature Ideas
Replies: 1 comment 1 reply
-
I think it's a good idea to add this to the docs indeed. Ended up here while trying to figure out how it works. Thanks @james0r! <div x-init="$watch('$store.darkMode.on', value => console.log(value))"></div> |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I see this is possible just like in Spruce, so it'd probably be of interest to others.
Did a demo to confirm it works -> https://codepen.io/James0r/pen/vYxPeqq?editors=1111
Beta Was this translation helpful? Give feedback.
All reactions