Re: Acceptable for CSS to add a "window.CSS" global?

On Mon, 13 Aug 2012 20:19:29 +0200, Tab Atkins Jr. <jackalmage@gmail.com>  
wrote:

> The CSSWG would like to add a new top-level object called "CSS" that
> we can hang several functions and constructors off of, so that we can
> avoid the excessive verbosity that's probably required if we just put
> everything on window

Cool! While reviewing some @supports tests just a few weeks ago I in fact  
wondered about the same thing. We tend to have long names and they're not  
always that easy to remember or use. And @supports corresponds to  
CSS.supports() sure sounds much nicer than supportsCSS(). And it's not  
like we have too few functions hanging directly off window.

Another benefit is that with a CSS top-level object, you can expand that  
in your debugger and hopefully get some relevant "documentation" right  
there, instead of looking for functions with "CSS" in them on window.

FWIW I really like it.

-- 
Odin Hørthe Omdal (Velmont/odinho) · Core, Opera Software, http://opera.com

Received on Tuesday, 14 August 2012 09:20:57 UTC