[whatwg] Web Storage: apparent contradiction in spec

Adrian Sutton adrian.sutton at ephox.com
Wed Aug 26 10:54:48 PDT 2009

On 26/08/2009 18:36, "Jens Alfke" <snej at google.com> wrote:
> I think there are lots of other use cases for web apps that would use local
> storage without ever syncing it to the cloud, simply because it's vastly
> easier to do. I can write such an app and host it on my cheapo personal
> website without having to worry about user account registration, storage and
> bandwidth costs for an unknown number of documents, tech support or legal
> liability if my server loses people's data, privacy requirements, DMCA
> takedown requests, etc. etc.

On the other hand, look at it from a user's point of view - where is the
data on disk?  How do I back it up?  The browser's local storage is very
opaque and hidden to the user so it's not a safe place to save important
data since it's unlikely to be thought of when it comes to backing up.

We do clearly have two types of local storage data though - one set is a
local cache and should be garbage collected automatically if I don't use the
site for a while or if space is tight.  As a user, I really want that
functionality - otherwise I have to either disable local storage and have
permission dialogs popping up all the time to make exceptions, or have an
ever growing database of rubbish on my drive.

On the other hand, there will be a handful of sites where I explicitly
decide that the data I create is important.  The natural tendency would be
to select a location on my disk where the local storage for that webapp
would be saved.  Then it becomes a visible, manageable file on my disk.
Devices like the iPhone where there's no file management, would probably
just have a flag to say whether it is permanent or not.

I'm not sure how this fits into what the spec says of course, but from a
user's perspective, I don't want to lose important data, but I also don't
want to keep every bit of local storage forever.  The spec really needs to
allow both, but have a flag to tell the application which mode is being


Adrian Sutton.
Adrian Sutton, CTO
UK: +44 1 628 200 182 x481  US: +1 (650) 292 9659 x717
Ephox <http://www.ephox.com/>
Ephox Blogs <http://planet.ephox.com/>, Personal Blog

More information about the whatwg mailing list