QuotaExceededError using Ionic Storage with a few

2019-04-23 05:50发布

问题:

I'm having this issue with Ionic Storage, this is the complete stack trace:

core.es5.js:1084 ERROR Error: Uncaught (in promise): QuotaExceededError: 
at c (polyfills.js:3)
at c (polyfills.js:3)
at polyfills.js:3
at t.invokeTask (polyfills.js:3)
at Object.onInvokeTask (core.es5.js:4140)
at t.invokeTask (polyfills.js:3)
at r.runTask (polyfills.js:3)
at o (polyfills.js:3)
at IDBTransaction.invoke (polyfills.js:3)

I'm using the settigs servis as recommended in Ionic super template.

this is happening testing on browser (Chrome)

回答1:

By chance, tonight I discovered that the hard disk of my windows PC was almost full, which was generating problems of virtual memory, and specifically in chrome problems with the local storage



回答2:

I had the same issue and discovered that my hard disk running short of space. Cleared the memory and it worked fine.



回答3:

Did you try this:

IonicStorageModule.forRoot({
  name: ‘__mydb’,
  driverOrder: [‘sqlite’, ‘websql’, ‘indexeddb’]
})