5 ms·
I have recently started using Tailwind. I've been writing CSS since it was invented in the 90s. I'd consider myself a CSS expert. I'm using Svelte (components).
by tristanb 4y ago
I have recently started using Tailwind. I've been writing CSS since it was invented in the 90s. I'd consider myself a CSS expert. I'm using Svelte (components). When Tailwind doesn't do what I want, I write a quick CSS class. I also don't like the long class strings in the HTML, and haven't yet found a good workaround for that, but in general. I like Tailwind.
- jeppester 4y agoThe workaround is to make components, so instead of having those long lists of classes copied around there's a component with those classes and the ability to take further classes.
- darraghenright 4y agoAre you familiar with @apply? I've found this useful when I notice that I am reusing styles for things that repeat again and again, like form fields or buttons. https://tailwindcss.com/docs/reusing-styles#extracting-classes-with-apply https://tailwindcss.com/docs/reusing-styles#extracting-class...
- tristanb 4y agoI am, but unfortunately modifiers are not supported unless you use layers, which don’t work in svelte components. So you can only use tailwind classes with no modifiers, which is mostly what I love about tailwind.