4 ms·
Yes I agree - it's nice to be able to see exactly what's happening without needing to dive into a rats nest of fragile CSS cascades.
by monkey_monkey 1y ago
Yes I agree - it's nice to be able to see exactly what's happening without needing to dive into a rats nest of fragile CSS cascades.
- deleted 1y ago[deleted]
- skydhash 1y agoWhy not use the web inspector? That’s usually the quickest way to see which style is applied to an element.
- paradox460 1y agoPeople would rather have to parse out a big dumb list of classes than look at the actual list of what properties affect something, with a clear ability to drill down into them. Its madness, akin to carpenters giving up hammers, preferring to use glue, because they hit their thumb a few times by accident
- skydhash 1y agoBased on the code I've seen, including written by old me, it seems more like designing the architecture of the CSS styles (and sticking to it) is something people don't like to do. Tailwind is just a tool that is nicer than using the style attribute on the element. I strongly prefer "button is-primary is-fullwidth" over the long list of tailwind classes.
- paradox460 1y agoSame. And all the arguments about using component libraries, like the op, fall flat when you realize components can have scope local styles
- sensanaty 1y agoOn the site I maintain at work, if I check literally any of the old components that don't use tailwind, what I see in the styles list of the devtools is 75 different variants of .card__wrapper or whatever all overriding each other, and it's often an abject nightmare trying to figure out which of the 75 different .card__wrapper (or is it .card { &.__wrapper} ?) classes is the one I care about at the moment.
- paradox460 1y agoClick over to the computed styles tab, and now you have a list of all the styles that apply to an element, regardless of source. Click the arrow next to one and it shows you where it comes from Also, have you ever tried to update old designs using tailwind? It's a disaster. Far easier to know what styles the ugly bem card class you mentioned apply to, rather than an arbitrary b-2 m-1
- vitaflo 1y agoThis is literally a rats nest of css cascades.
- softwreoutthere 1y agoIts atomic though, which is easier for some to reason about. I use devtools.
- omnimus 1y agoIt is not. Utility all classes have basic specificity of 0-1-0. There is no cascade just order of classes that all have same specificity.