Skip to content
Discussion options

You must be logged in to vote

Hi,

Seems that if setting store atom, and using atom from component, the component will not react, is it planned ?

const store = createStore() store.set(fooAtom, 'foo')

and then

useAtom(fooAtom)

You should provide a store with Provider.

<Provider store={store}>

then useAtom(fooAtom) works under the provider.

Replies: 4 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@dai-shi
Comment options

Comment options

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

wootra Mar 10, 2023
Collaborator

Answer selected by prbxr
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants