prettier/prettier

Prettier dogfoods itself with eslint + cspell + knip + tsc on top, and alint adds 5 net-new gates that none of those tools sees, including the per-language-plugin layout the entire codebase architecture rests on.

Narrative
Adds a structural floor on top of mature tooling
Rules
68
Last revalidated
Engineering reference
README on GitHub · .alint.yml

Why this case study matters

prettier is the cleanest “structural floor on top” data point in the Wave 1+2 inventory so far: prettier is itself a code-formatter (it dogfoods), its existing tooling is mature and tightly curated (ESLint flat-config + 9 internal prettier-internal-rules/* + the self-prettier --check + cspell + knip + tsc + 5 custom node validation scripts), and yet the plugin-shape conventions that the entire codebase architecture rests on are encoded only in code review and folder-name memory.

For any plugin-architecture project, webpack, rollup, vite, babel, postcss, the “every plugin has shape X” rule is universal and rarely enforced. prettier shows what the structural floor looks like when it lands cleanly under a mature tool stack.

Headline catch

prettier ships eight plugins under src/language-*/ (js, css, html, markdown, yaml, json, graphql, handlebars). Each one must export index.js (parser/printer/options) plus languages.evaluate.js (linguist-languages lookup table consumed at build time). A plugin that drops languages.evaluate.js would silently be omitted from the production bundle. Yet nothing on disk asserts this contract. Same thing for the 1:1 mapping between plugins and changelog_unreleased/<lang>/ category directories: a new plugin landing without its category dir ships fine, and PR notes for it have nowhere to go.

Alint’s for_each_dir over src/language-* is the missing structural floor. Five net-new gates that prettier’s existing ESLint + prettier-itself + cspell + knip + tsc stack does not enforce today:

Where alint earns its keep here

Future story angles

The factual engineering writeup (tooling inventory, mapping table, gap catalogue, validation status footer) lives in the public alint repo at github.com/asamarts/alint/tree/main/examples/prettier-prettier/README.md.