News for hackers. Stuff that matters.
Re:CSS sucks because we don't bother learning it (2022) by bryanrasmussen on Monday January 05, 2026 @05:28PM (#46505968)
also let us suppose I have the following

.one span {color: red}

.one span {color: purple}

inside of a CSS file.

Again I don't think I could consider that as mutating state.

This is mutating state

let color = "red";

if (x} { color = "purple"; }

because it mutates the variable value at run time based on something else.

The variable at different parts of the program have different values.

If you read .one span with the CSSOM in the above example it will always return color: purple.

That is not a mutated value, that is poorly written code that has been compiled down.

There are no comments on this comment yet.