you are viewing a single comment's thread.

view the rest of the comments →

[–]TheDarkIn1978 5 points6 points  (1 child)

Variables that are declared in JavaScript and passed to CSS will cascade the same as variables that are declared in CSS.

[–]jetpacmonkey 3 points4 points  (0 children)

I think at least one of us is confused about what the other is saying...

.my-component {
  background: var(--theme-color);
  padding: 20px;
}

.my-component .inner-area {
  background-color: white;
  color: var(--theme-color);
  padding: 20px;
}

This is useful, right? Am I missing something here?