5 ms·
What did you need Tailwind for before that you couldn't do in normal CSS? Doesn't Tailwind map pretty much 1:1 to CSS?
by crummy 2y ago
What did you need Tailwind for before that you couldn't do in normal CSS? Doesn't Tailwind map pretty much 1:1 to CSS?
- ervine 2y agoYes.
- BeetleB 2y ago> Doesn't Tailwind map pretty much 1:1 to CSS? Much of it does, but not all of it.
- _heimdall 2y agoDo you have an example that Tailwind can do that can't be done in CSS?
- BeetleB 2y agoI'm going off a claim from the Tailwind site :-) The original question wasn't whether Tailwind can do something CSS can't, but whether it was a 1:1 mapping. Can regular CSS do media queries all within the element's style attribute? I believe Tailwind also utilizes JS to get some convenience features to work.
- _heimdall 2y agoOh gotcha, I must have just misunderstood the previous comment. I want to say that tailwind also can't do inline media queries, but that's getting really nitpicky and pedantic. You can at least add a class inline that Tailwind creates a media query for in CSS, that is really handy.
- yurishimo 2y agoTailwind doesn't generate any JS at all. The final build is 100% CSS.
- rayrrr 2y agoEvery programming language maps 1:1 to CPU instruction sets, but very few humans want to speak CPU language directly…hope that helps.
- xigoi 2y agoProgramming languages are more human-readable than CPU instructions, as opposed to Tailwind, which is less human-readable than CSS.
- dankobgd 2y agoIt's a horrible way to do what css can do but in a dumber way with added tooling. It is used by people that don't know css and this is where the problems start
- jitl 2y agoI’ve been writing css/scss/stylus/linaria/whatever styling stuff for 18 years and I think tailwind improves life much more for css knowers than for css noobs. I prefer it over raw css for sure - I’ve written the same shit enough times that I’m happy to take some shortcuts and more than willing to pay for some tooling to do so. Tailwind hands out less abstraction rope compared to vanilla css and sass and all the rest, so much lower chance I open up a file and find some convoluted special little kingdom of abstractions that need to be handled carefully. Reduced cognitive load in the long run for a small up front learning/setup cost.