Tailwind and the Beauty of Ugly Code
There are enough people who advocate for Tailwind that I can&#x27;t dismiss them in good conscience, but if you put a gun to my head and forced me to give my honest opinion, I can&#x27;t think of a single problem that Tailwind solves that isn&#x27;t better solved by web components and scoped CSS, BEM, or a decent CSS-in-JS library.<p>When I see articles praising Tailwind, they&#x27;re almost always comparing it to the worst possible way to write CSS -- a mixture of arbitrary classnames that get reused across components and semantic styles that refer directly to HTML and use child selectors to target specific elements.<p>Well yeah, if you compare Tailwind to that, it probably looks great. If you compare JQuery to building HTML templates in PHP using string concatenation, JQuery probably looks great too.<p>Again, I can&#x27;t dismiss it, the people advocating for it must know about these other solutions. I can&#x27;t dismiss them. But I don&#x27;t understand it. And the articles that are written about why it&#x27;s good are entirely unpersuasive. They&#x27;re talking about problems that I consider to be already solved.<p>People advertise Tailwind by saying &quot;we want the styles to be based on the component.&quot; Yeah, I want that too, but it sure looks Tailwind is a really inconvenient, cumbersome way to do that. You can scope CSS to components if you want to, that&#x27;s not something that requires Tailwind.