joe-bell/cva
Class Variance Authority observed · 2026-08-28
Health v2 · maintenance only
67/100
- Activity 99
- Release rhythm 8
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-02. Adoption (stars, forks) is never an input.
- gap_med: n/a
- age_days: 1704
- days_rel: 645
- days_push: 9
- n_releases_24m: 1
Adoption not part of the score
6880 stars · 136 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-29, confidence not recorded
Class Variance Authority (cva) is a tiny TypeScript library for building type-safe, variant-driven class names for UI components, with first-class Tailwind CSS support. It handles variant props, compound variants, and defaults so developers don't have to manually match classes to props.
Use cases
- create type-safe component variants in react
- manage tailwind css button variants
- build a design system with variant-driven class names
- avoid manually mapping props to css classes
- extract variant prop types with typescript
- compose and extend styled ui components
When to choose
- you use Tailwind CSS or write your own CSS and want type-safe variants
- you want a tiny, framework-agnostic alternative to CSS-in-TS libraries like Stitches
- you need compound variants and default variant values
- you want full control over your stylesheet output
When to avoid
- you want responsive variants built in - cva doesn't support them
- you prefer a styled API or CSS-in-TS solution like Stitches or Vanilla Extract
- you need component composition handled for you out of the box
Facets
library · maturity stable
ui-components css-framework frontend-framework type-system frontend web-development web-design bun browser cross-platform tailwind-css class-names variants typescript design-systems component-variants nodejs deno
9 sources
- readme: https://github.com/joe-bell/cva · fetched 2026-08-28 · 625ef490f54b
- homepage: https://cva.style · fetched 2026-08-29 · d8970a897f66
- site_page: https://cva.style/getting-started/installation · fetched 2026-08-29 · 6196d86a3e2b
- site_page: https://cva.style/getting-started/variants · fetched 2026-08-29 · efdfcac5cb61
- site_page: https://cva.style/getting-started/typescript · fetched 2026-08-29 · 02cb61d610d4
- site_page: https://cva.style/getting-started/extending-components · fetched 2026-08-29 · 17b9b83d823d
- site_page: https://cva.style/getting-started/composing-components · fetched 2026-08-29 · 36c84deaf8b0
- site_page: https://cva.style/faqs · fetched 2026-08-29 · ec8a5b4a4496
- site_page: https://cva.style/beta · fetched 2026-08-29 · bd82958eba2f
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| joe-bell/cva | main | 67 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem