4 ms·
> -Previous installed chrome app matches the HTML5 api, the new chrome apps has a lot of restriction where you have to totally rewrite you code in terms of stor
by daleharvey 13y ago
> -Previous installed chrome app matches the HTML5 api, the new chrome apps has a lot of restriction where you have to totally rewrite you code in terms of storage. i.e. Chrome.storage instead of localStorage; All chrome storage is async.
I belive this is only localStorage right? (indexedDB is still available afaik)
Firefox OS had mentions of disabling localStorage, its been a huge problem due to its synchronous API, I dont think it did end up being disabled though, I would really like to see localStorage being (slowly) deprecated and an async api (possibly even just a helper for idb) being promoted as an alternative full web standard as opposed to chrome specific API's coming in here
- justincormack 13y agoSynchronous local storage on a phone would be a real problem due to lags, on desktop it might be OK...
- lucian1900 13y agoIt's terrible on a desktop as well, even with an SSD. It fsyncs, which blocks the entire page.
- tyre 13y agoindexedDB is available with an entirely async API. Bring on the callbacks!
- daleharvey 13y agoYup, we have a shared helper in Firefox OS on top of IndexedDB that all the apps use (localStorage is as close to banned as it can be) (https://github.com/mozilla-b2g/gaia/blob/master/shared/js/async_storage.js https://github.com/mozilla-b2g/gaia/blob/master/shared/js/as...) However thats fine when you are building your own apps, but I meant as a long term solution to the web platform, if localStorage needs disabled on one platform in favour of a propietary API, maybe its best to replace it with a non proprietary web api