3 ms·
Tailwind is not an abstraction that makes CSS easier. You still have to know all the CSS. The benefit is it makes writing CSS faster. Writing CSS in the markup
by spencerchubb 4y ago
Tailwind is not an abstraction that makes CSS easier. You still have to know all the CSS.
The benefit is it makes writing CSS faster. Writing CSS in the markup just makes more sense. People say that markup and style should be separate to adhere to "separation of concerns". But in fact, markup and style should be coupled, because they both pertain to the UI, visuals, and aesthetics.
- toastal 4y ago> necessarily coupled As a counter: I see a lot of bad markup ordering when you turn off stylesheets or use a TUI browser. You should be laying out your markup in a logical sense (within some reason) where it's easy to parse without styles and navigate with a keyboard—decoupled from styles. CSS grid and the `order` property let us easily move around elements for visual ordering and that this can (and likely should) happen shows that the data layer (HTML) has separate concerns from the visual presentation layer (CSS). Yes I want my first button tabbed to in your modal to be the primary action button even when it is displayed to the right of the cancel button and that's a heck of a lot easier to order it ‘correctly’ and style it in a different order for aesthetics or better visual parsing.
- eropple 4y agoThe thing I continue to not get, and I've used Tailwind enough to at least have an idea of what it wants me to care about, is why miles and miles of utility classes are better for that than, say, styled-components and an object merge.