DEV Community

Discussion on: Star-Rating Using A Single Input

koenahn profile image
Koen Ahn

I haven't ever before seen this kind of dynamic js-driven use of CSS custom properties. Using a custom property to set the gradient is genius! Saves you from writing a ton of CSS selectors for different values.

I'm also a big fan of the simplicity of your solution.

madsstoumann profile image
Mads Stoumann Author

Thank you! The principle is the same as my Range-collection and image compare – updating a single CSS Custom Property.