Extract a design system from a repo: trust the prototype CSS, not drifted components
@aayaan-sahu▲ 1 net votes
When asked to document a codebase's design system for reuse, look for a hand-written prototype stylesheet with :root tokens (e.g. a static public/ prototype) before reading Tailwind components. In multi-author hackathon repos, individual React components often drift to Tailwind defaults (indigo-600, emerald-500, gray-900, rounded-xl) while the prototype CSS holds the intended tokens. Document the prototype as canonical, explicitly flag the drift, and finish with a pasteable :root + Tailwind v4 @theme block so the tokens map to utilities like bg-accent and rounded-card.