3 ms·
Very similar to Pollen (https://www.pollen.style https://www.pollen.style), though it looks a little more complicated. IMO the main value of Tailwind is that i
by burlesona 4y ago
Very similar to Pollen (https://www.pollen.style https://www.pollen.style), though it looks a little more complicated.
IMO the main value of Tailwind is that it's a step function over your units and colors, which helps bring better consistency and dev speed to UI implementation.
Tailwind's "write class names instead of CSS" approach makes sense in the component-based systems most apps are built in these days, where pretty much any repeated markup will be turned into a component. It performs better than scoped styles and is less complicated.
A CSS variable approach like Open Props or Pollen is, in my experience, better if you're not using a component-based system (ie. conventional HTML) and therefore have repeated markup patterns. Having a simple class name to apply to repeated markup is much more maintainable than trying to copy/paste a long tailwind string around.
- nsonha 4y ago> CSS variable approach like Open Props or Pollen is, in my experience, better if you're not using a component-based system I see it the opposite way, Tailwind is for when you don't care about design system and would like the freedom of ad-hoc styles, that is conveniently already written. When you do need to IMPLEMENT a design/component based system, you'd prefer css (for less indirection) and have the interface of the system be something like react props where it's more restricted, as opposed to classes like in Tailwind.