Initing a zustand store with outside data
I’m using a Zustand store to manage state.
I want to fill my store with data from an API; currently, my store has an init() function that does the data fetching and setting. However, this is a bit messy. The store is created with all empty values; init() is called from a component, and then the store is useable.
Initing a zustand store with outside data
I’m using a Zustand store to manage state.
I want to fill my store with data from an API; currently, my store has an init() function that does the data fetching and setting. However, this is a bit messy. The store is created with all empty values; init() is called from a component, and then the store is useable.
zustand store how it works with multiple session
Please bear with me 🙂 I am working on a small nextjs hobby app and wanted to test zustand library with it. I managed to use next-auth with firestore adapter and I have a session created and also can access in my client page using getSession.
Create store with zustand in Nextjs craeteStore()() vs createStore()
I was using zustand in react, now I start learning Next and try to set up zustand store, in documentation they create store like so:
I’m trying to build a mining web app just like Bondex, my tech stack is Nextjs, Zustand, Nextjs API. Tips and overview on how to go about it, please
I’m trying to build a mining web app just like Bondex, my tech stack is Nextjs, Zustand, Nextjs API. Tips and overview on how to go about it, please. It has to be persisted and when the user leaves the site, it should not reset