Replies: 1 comment
-
have a look at the experiment going on here: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Good day everyone
We are working on an App which must work offline, because of that a large amount of data can be download prior to going offline. To store the data we are using a
PersistQueryClientProvider
with a persistor based on idb-keyvalIf the user goes offline then a large set of data is downloaded and stored in indexedDb, we then often end up with 50MB or more of storage taken by IndexedDb.
The problem is that when we run a mutation, it seems that the whole persitClient object is written in IndexedDb and since that object can become quite large when offline it creates performance problems. Are there any way we can avoid writing the whole object in indexedDB and for example only the mutation behind the change ?
I have looked at the source code and maybe we could write
storagePersistor
and by subscribing togetMutationCache
,getQueryCache
, together with our ownhydrate
anddehydrate
method. For maybe there's a simpler and better way ?Beta Was this translation helpful? Give feedback.
All reactions