W3C home > Mailing lists > Public > www-style@w3.org > April 2013

Re: [css-variables][naming] Renaming 'var'

From: Sylvain Galineau <galineau@adobe.com>
Date: Tue, 16 Apr 2013 07:45:07 -0700
To: Pete Boere <pete@the-echoplex.net>
CC: "Jens O. Meiert" <jens@meiert.com>, fantasai <fantasai.lists@inkedblade.net>, "www-style@w3.org" <www-style@w3.org>
Message-ID: <CD92B0F7.2540%galineau@adobe.com>




>Beacuse if I'm styling a web page with coca-cola branding I'll want to
>use a variable named 'red' to store the exact >brand color. Since 'red'
>is also color keyword, 'set-red' to me implies you might be messing with
>the keyword value >itself.
This is not persuasive since 'red' is not the only option in this case
('brand-color' seems more like what it is). No prefix naming convention
will prevent anyone from using poor variable names that will confuse them
later.


>'var-' is less generic than 'set-', so the intention is clearer.

var- and var() are completely generic hence the suggestion to have set-
and get- to convey which does what.
Received on Tuesday, 16 April 2013 14:47:51 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:10 UTC