W3C home > Mailing lists > Public > whatwg@whatwg.org > December 2012

Re: [whatwg] Make DOMStringMap constructable, and el.dataset writeable?

From: Ian Hickson <ian@hixie.ch>
Date: Sat, 1 Dec 2012 00:01:29 +0000 (UTC)
To: "Tab Atkins Jr." <jackalmage@gmail.com>
Message-ID: <Pine.LNX.4.64.1211302359120.12469@ps20323.dreamhostps.com>
Cc: WHATWG List <whatwg@whatwg.org>
On Fri, 30 Nov 2012, Tab Atkins Jr. wrote:
> She's making a game, where the game initialization script expects 
> certain types of elements, and for the initial state data of the 
> elements to be present in data attributes on them.  She'd like to be 
> able to pause the game, shifting all the state data into localStorage, 
> then later resume by pulling it back onto elements before starting the 
> game script.

Presumably you wouldn't necessarily want to grab _all_ the data-* 
attributes, since some might be from other libraries, or temporary 
transitional values used for animations or tracking things like mouse 

> It would be somewhat cleaner if she could simply construct a
> DOMStringMap and assign it

I don't really understand what you would do with the DOMStringMap and 
localStorage. Can you elaborate?

Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Saturday, 1 December 2012 02:33:53 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:50 UTC