Replies: 2 comments 3 replies
-
This is the way how we recommend to use Nano Stores. Since we believe that you should separate logic from UI components, it means that we recommend to keep logic (atoms) in separated files. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Can you show the component’s code? Do you export do like this: export const store = atom() or do you do something like: export const value = useStore(store) |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I'm using Astro + React and when I export an atom from inside a component, other components that use this atom (with useStore) does not see updates.
The atom needs to be moved to an external file.
Any idea why that is so?
Thanks
Matt
Beta Was this translation helpful? Give feedback.
All reactions