Re: CSS Variables Draft Proposal

On Wed, Feb 16, 2011 at 8:15 PM, David Singer <singer@apple.com> wrote:
> On Feb 17, 2011, at 9:11 , Tab Atkins Jr. wrote:
>> Something like what I called Modules in
>> <http://www.xanthir.com/blog/b49w0>.  That proposal is essentially
>> just brainstorming, as we don't have immediate plans to even try an
>> experimental implementation, but it roughly outlines our thinking on
>> this matter.
>>
>> Scoped stylesheets may also be used to contain variables if you really
>> don't want to leak them out to the global scope.
>
> But if module names are global (as I suspect they have to be), it seems like you have swapped a potential problem of unintended clashes of variable names, into a potential problem of unintended clashes of module names.  Which is a smaller problem, to be sure, and to be a real problem, you'd have to have both the module name and a variable in that module unintentionally collide, which also reduces the likelihood. But it doesn't appear to close the door, as it were.

That doesn't appear to be a problem in languages like Python, so I
won't worry about it for CSS.  ^_^

~TJ

Received on Thursday, 17 February 2011 06:00:17 UTC