Hey @dsilva (and anyone else that can help )
I’ve been trying to get the storage API going and hit a weird problem.
Firstly, I’ve noticed that getItem(key) returns success, even if nothing has been written to the key yet. The data value is null, which I guess is what you have to check to test for this case. I presume that is the intended behaviour, it just caught be my surprise.
But the actual problem I am seeing is this -
I’ve confirmed that I can read and write a simple test string to/from a key, but when I try the larger string that represents the document I am saving, things go wrong. setItem() returns success, but getItem() gives the same outcome as when it’s a new key - success plus null value.
Can there be something about the content of the data that would cause it to fail in this way? My document contains code, a mix of CSS, HTML, javascript and other things. I tried a quick test, putting a code snippet in my simple test string example, and that still works, but I suppose there could be some very particular content that is causing the issue.
Here are some screenshots.
The working version with a simple test string-
The failure with the real string-
[…]