-
Notifications
You must be signed in to change notification settings - Fork 215
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Loading State from store.get #213
Comments
Did you figure it out? |
I don't exactly remember since it's been so long, but I think the solution involved using Let me know if it works. |
Thanks for the reply. The
|
So it's working as expected now? |
I don't think it's the intended way. But I found a way I guess. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Context:
I have a grid of images whose order can be changed by the user. I want to save the modified order and have it accessible so that it persists on a page refresh or when the user revisits the form.
Ideally, the order should be communicated to the server and loaded from the server as well, but currently the 'get' method is not working even with the localStorage, as described in the store documentation.
Problem:
I tried the get and set methods from 'store', but only the set seems to work.
Whenever I reorder the images, the localStorage gets updated accordingly, but the images go to their default positions on page refresh.
Key-value pair in localStorage:
example : 60b4f506a8ee53a1d8aad392|60b4f506a8ee53a1d8aad394|60b4f506a8ee53a1d8aad393
I tried to use
but I'm unsure where to call this.
How can I ensure that the images are positioned according to the positions last set by the user when the page loads?
Any help in this matter is highly appreciated. Thank you for your time.
The text was updated successfully, but these errors were encountered: