|
|
|
|
|
by alunchbox
1722 days ago
|
|
It's a different mentally. From tailwinds landing page it explains the reasoning. A big one is that you don't have to think about abstractions or relationships between classes. But instead think in terms of utility and really making it a language of it's own right. I was hesitant but gave it a go. It was quite enjoyable and productive. There's also the @apply which enabled you to still remove the duplication or build your own utilities on top of their skeleton. Don't knock it till you try it! |
|
1. Yes it's almost another language, you have to memorize shorthand syntax that is sometimes unintuitive.
2. I need something cross-platform, not a web specific tool. I've moved to RN Stylesheets for both native and web and I don't deal with normal CSS at all.
3. I don't have a problem naming classes, I find it helps maintaining later at the cost of slightly more time upfront. Plus you can compose multiple classes based on states. You can also reuse those classes within the same component. Seems difficult to do that if you inline things. If I did want to skip naming I would use something like JSXStyle/SnackUI instead of Tailwind (direct props, not shorthand strings).
Tailwind is great for web designers wanting to iterate a design quickly, that's about it. I feel you pay for it later though. It's ugly and unreadable at a glance. We just circled back to inline styles.