6 ms·
Author here, I have a few custom classes that look like more traditional CSS. Tailwind gives an example[0] of how to do this in their docs. I have about 15 of t
by 01brett 5y ago
Author here, I have a few custom classes that look like more traditional CSS. Tailwind gives an example[0] of how to do this in their docs. I have about 15 of these extracted classes. I use them for common styling patterns, such as transforming "flex items-center justify-center" to "flex-center," or to unify styling on components I haven't abstracted into a styled version, such as "listbox-option" or "flyout."
[0] https://tailwindcss.com/docs/extracting-components#extracting-component-classes-with-apply https://tailwindcss.com/docs/extracting-components#extractin...
- danielvaughn 5y agoI've been considering an approach like this, but I don't want to risk going back down the path of "having to name things".