Does SWR cache persist on page reload ? #592
Answered
by
sergiodxa
jeremytenjo
asked this question in
General
-
Does SWR cache persist on page reload ? |
Beta Was this translation helpful? Give feedback.
Answered by
sergiodxa
Aug 7, 2020
Replies: 1 comment 3 replies
-
It doesn't, it's all in-memory, but you can use swr-sync-storage to keep your SWR cache synced with localStorage or sessionStorage and it will hydrate your cache from there when your app load. |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
jeremytenjo
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It doesn't, it's all in-memory, but you can use swr-sync-storage to keep your SWR cache synced with localStorage or sessionStorage and it will hydrate your cache from there when your app load.