6 ms·
> wouldn't you say that when naming things for the purpose of targeting them with styling, what they look like is indeed what they are? What do you mean? A "co
by thinkloop 7y ago
> wouldn't you say that when naming things for the purpose of targeting them with styling, what they look like is indeed what they are?
What do you mean? A "comment" is likely to stay a "comment" forever, whereas its bold'ness or italic'ness can/will likely change relatively often.
- klum 7y agoWell, yes. So, in the hypothetical situation where classes are added just for styling, is it a given that the correct way to name it is a way that stays the same when the styling changes?
- welly 7y agoAnd therein lies the problem. You don't add classes just for styling. This is terrible practice that I thought we'd stopped doing.
- thinkloop 7y ago> in the hypothetical situation where classes are added just for styling OK, a style-based class naming system > is it a given that the correct way to name it is a way that stays the same when the styling changes Not with a style-based naming system, in that case it's ok for the class name to change, and you can expect it to change often, which a lot of people argue is ok. But like @welly said, herein lies the problem, or preference. The argument is exactly about whether you should name things in unchanging "decoupled" ways, or whether that doesn't work out in practice and it's simpler to just have utility styles.