Menu

1 / 2

My whole design system is one 30-line CSS file

DEV Community: css·Kamran Khan·about 17 hours ago
#m8AQhYRg
#devtocss#devto#dev#scrollbar#slate
Reading 0:00
15s threshold

Here's my entire global stylesheet, in full:

@tailwind base ; @tailwind components ; @tailwind utilities ;

body { @apply bg-slate-100 text-slate-800 antialiased; }

/* Custom scrollbar */ ::-webkit-scrollbar { width : 10px ; height : 10px ; }

::-webkit-scrollbar-track { background : #f1f5f9 ; }

::-webkit-scrollbar-thumb { background : #94a3b8 ; border-radius : 8px ; border : 2px solid #f1f5f9 ; }

::-webkit-scrollbar-thumb:hover { background : #64748b ; }

Enter fullscreen mode

Exit fullscreen mode

That's it. Three Tailwind directives, one body rule, and a styled scrollbar.

The kit's "look" doesn't come from this file. It comes from repeating the same utility combinations everywhere — rounded-xl bg-white p-6 shadow-sm is my card, text-sm font-medium text-slate-500 is my label. My StatCard component is literally that combo with four accent colour choices. The design system is a habit, not a file.

So why the scrollbar?…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.