When I set mode to use local storage and try to request and get a response more than 5M, it will cause the error: Uncaught QuotaExceededError. That is because it exceed the build-in localstorage quota.
I will suggest the following two ways to fix:
- have a quota settings first by default 5M, then when putting, if the coming response is great than the quota, it should ignore and output a warning in console.
- have a compress settings, when putting, if the coming response is great than the quota, it should use the passing compress interface to compress before put it into local storage.
Cheers,
Ron