Pinia, Local Storage ... :(
Hey,
So I created a store to save a cart Id, its wordking great! exepect when I refresh the page... the store gets reset. So I then started using local storage to store the ID then fetch it back like below:
its still working when going between pages, local storage is getting updated but when I refresh the page all I get is null π¦
11 Replies
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View
Yes same issue
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View
yeah I seen this and tried
problem is its setting to local storage but I cant get it
I think the issue is here to get the local storage data
`
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View
here?
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View
sorry I don't know what that means lol
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View
`
just nuxt wont read from my local storage but it will write to it π¦
Unknown Userβ’2y ago
Message Not Public
Sign In & Join Server To View