wiki:Cleanroom implement CSS Custom Properties

Version 1 (modified by, 10 years ago) (diff)


Attendee: ericc, hober, dhyatt, Zoltan, asterns, abucur

Status of Spec

  • Firefox implements the full specification because CSS WG has stripped down the parts Firefox didn't implement.
  • New syntax uses "--" prefix to define a new CSS variable and uses "var()" function to reference a variable. - There was a very long thread on CSS WG.
  • Custom properties are all inheritable - this may pose an implementation challenge; we probably need a chain of custom property bundles.
  • Custom properties aren't exposed in computed style.

Historical Implementations

There are two historical implementations: the one implemented by hyatt and someone at Google. The Google implementation had many architectural problems.

The hyatt implementation was taken out of the trunk because CSS WG could not agree on the exact syntax. It also supported changing the value of a CSS variable in scripts. var() function parser could be pulled in from the hyatt's implementation but the patch may not apply well due to it being so old.


  • Websites that don't use variables shouldn't slow down.
  • Breaking cycle - appears to be spec'ed but invalidating the value with cycles might be challenging in the implementation.

Who should implement?

  • Hyatt says this would be fun to implement.
  • Alan says he might be able to find people who can help.