Re: [css-variables] using variables in shorthands

On Sun, Mar 11, 2012 at 1:05 AM, Shane Stephens <shans@google.com> wrote:
> Hi Florian,
>
> I don't think variables should be able to encode multiple values (like
> 1em 2em or 1em 2em 3em 4em), because these are a nightmare to type (as
> in type check, not type out).

This cuts out some major use-cases, like being able to encode a
text-shadow or a font stack.  I'm against this limitation.  I'm aware
that it makes things harder, but it also makes things much more
*useful*.

It also cuts out part of the secondary use-case of using Variables
just to pass around arbitrary JS data with selectors and the cascade.
You'd have to encode your multi-part value in a string and then strip
off the quotes when you received the string from the CSSOM.

~TJ

Received on Sunday, 11 March 2012 13:09:03 UTC