# shuding/react-wrap-balancer

Simple React Component That Makes Titles More Readable

Repository: https://github.com/shuding/react-wrap-balancer
Canonical: https://ross.abutalabs.com/products/react-wrap-balancer
Homepage: https://react-wrap-balancer.vercel.app
Language: HTML
License: MIT
License Family: permissive
Topics: react, typography, wrapping
Last push: 2026-03-25T08:43:27+00:00

## Health v2 (maintenance only)
Score: 56/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 74, release rhythm 8, longevity 99
- inputs: {"age_days": 1392, "days_push": 161, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 4206, forks 62 (observed 2026-08-28T04:08:39.037068+00:00)

## What it is
A small React component that balances text wrapping in headings so lines have more even widths, avoiding single hanging words on the last line. It uses an O(log n) resize algorithm, supports SSR and streaming SSR, and falls back to native CSS text-wrap: balance when available.

## Use cases
- balance text wrapping in react headings
- avoid single word on last line of a title
- make headlines more readable across viewport sizes
- responsive typographic text balancing in react
- use css text-wrap balance with react fallback
- balance multiline text in next.js app

## When to choose
- You have React 16.8+ headings or titles that wrap awkwardly on different screen sizes
- You need SSR/streaming SSR-compatible text balancing without layout shifts
- You want a tiny (~1 kB) drop-in component with native CSS balance fallback

## When to avoid
- Your project is not React-based
- You need to balance arbitrary block content rather than short text like titles
- You must support IE11 or very old browsers lacking ResizeObserver

## Facets
- artifact type: library
- maturity: stable
- function: ui-components, frontend-framework, templating
- domain: web-development, frontend, web-design
- platform: browser
- tags: react, typography, text-wrapping, text-balance, ssr, responsive-design, nodejs, web-server

## Member repositories
- shuding/react-wrap-balancer (main) score 56

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:39.037068+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:22:30.947269+00:00, confidence not recorded.
  - readme: https://github.com/shuding/react-wrap-balancer (fetched 2026-08-28T04:08:39.037068+00:00, sha cf7e970cec35)
  - homepage: https://react-wrap-balancer.vercel.app (fetched 2026-08-29T09:12:42.976012+00:00, sha 36dbd6958845)
- Data as of 2026-08-30T08:39:29.467469+00:00.
