|
|
|
|
|
by blowski
1042 days ago
|
|
I can sum up what I like about Tailwind in the following code: ``` (in CSS)
a.link {
border: red;
}
a.link:hover {
border: blue;
}
```
``` (in Tailwind)
<a class="border-red hover:border-blue">
```
It's much easier in Tailwind for me to see locally what's going on with that styling. If I lived in this code all the time, or I was good at structuring CSS, then maybe the first would be more appealing. But I'm a shit at CSS, it always turns into an unmaintainable mess, and I look after a lot of different projects that I might not touch for 6 months. So Tailwind's approach is easier for me. |
|
And when the designer change his mind and border-red should not be used anymore?
And what if you have small changes, e.g.
```
<button class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded">Button 1</button>
<button class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-3 px-4 rounded">Button 2</button>
```