This situation is very unfortunate however as a place holder to maintain WebStorage and legacy. Why not in the meant time shim local storage. At least until Google finally capitulates and brings back localstorage; which is silly to remove.
indexDB loads the save information when the app starts. This is done prior to any WebStorage the c2 app uses.
All use of WebStorage localstorage works only on temporary in memory data.
then developers can make a choice on how often the temp storage is saved to the asynhronous long term storage(indexDB?)
1. On change.
2. On Layout change
3. Only on Action
This way the old system doesn't break as synchronous data storage is maintained. Speed(negligible) is improved as it's always memory storage.
Alternatively there could be a more advanced storage system. There is the one above that could be simple and automated. However the one above I would have concerns about large groups of data using lot's of memory. So an option would to provide an AJAX style memory system for large blobs of data and the above sample for small chunks.
And finally I would also like to add this.
local storage and session storage by default without user intrusion have limits of 5mb each. To by pass that 5mb require permissions and or user request. 5mb is small, but fine most of the time.
indexDB offers 50mb as a base storage before requiring user intrusion to functioning of the app.
So there are solutions to the problem. I don't really feel that the suggestions are hacky, but instead more in line with the intention of how indexDB should work. Instead of assuming that every piece of information is now based on ajax. Now the main storage Dictionary is ajaxed.