Tailwind Tips I Wish I Knew Earlier
Monish SoniFullstack Developer
Mar 2025·1 min read
Tailwind CSSCSS
Tailwind CSS feels effortless once you stop fighting it with one-off pixel values and start leaning on consistent design tokens.
Use Semantic Opacity Tokens
Instead of hardcoding separate light and dark hex colors on every card, using bg-foreground/[0.02] and border-foreground/10 automatically adapts across themes.
Three Habits That Pay Off
- Design mobile-first, then layer
sm:andlg:overrides. - Extract small React components instead of overusing
@apply. - Use
group-hoverfor card micro-interactions without extra state.
