Component

AlphabetizeWords

It transforms the actual letters inside every word while preserving spaces between words. The milled sentence is visibly different and reversible, making alphabetical order a needlessly destructive editorial tool.

Possible use

It could let a reviewer inspect a sentence as a pile of letters, or let a presenter turn an agenda line into an alphabetical artifact before restoring the readable copy.

Reasonable alternative

A reasonable local alternative is leaving the copy intact and using a one-off string utility for analysis. A reusable word mill makes readability subordinate to a sorting rule.

01 / Preview

Try it yourself.

Preview Interactive
Alphabetize wordsOriginal order
As submitted

Keep the useful sentence readable

Mill the label to sort each word's actual characters in place.

Mechanism
1
Start with a readable sentence.
2
Mill the words to sort each word’s real characters.
3
Restore reading when alphabetical order has gone too far.

02 / Usage

Put it somewhere.

example.tsxTSX
import { AlphabetizeWords } from "gra-ui";
import "gra-ui/styles.css";

export function MilledNotice() {
  return <AlphabetizeWords label="Keep the useful sentence readable" />;
}

03 / API

Small surface area.

PropTypeDescription
labelstringThe sentence whose word characters are sorted in place.