2 ms·
> How can we reuse constants that are defined in a single place? The answer for this is already in your browser: CSS custom properties http://caniuse.com/#feat
by balloob 9y ago
> How can we reuse constants that are defined in a single place?
The answer for this is already in your browser: CSS custom properties http://caniuse.com/#feat=css-variables http://caniuse.com/#feat=css-variables
On top of that the CSS working group is working on ::part and ::theme pseudoselectors to help theming across components. Brief intro in this Polymer Summit 2017 talk: https://youtu.be/rvpJ5O0W_6A?list=PLNYkxOF6rcIDP0PqVaJxqNWwIgvoEPzJi&t=1180 https://youtu.be/rvpJ5O0W_6A?list=PLNYkxOF6rcIDP0PqVaJxqNWwI... (skip back to 16:17 to hear why the CSS mixins proposal didn't work out)