← All open source projects

Prettier

prettier/prettier

Prettier is an инструмент форматирования с жестким стилем for JavaScript, TypeScript, JSX, JSON, and other formats: one code style without manual arguments.

Forks 4,755
Author prettier
Language JavaScript
License Unknown
Synced 2026-06-27

What it is

Prettier is an opinionated code formatter. It supports JavaScript, TypeScript, Flow, JSX, JSON, and other formats.

The project appeared as an answer to endless arguments about spaces, line breaks, quotes, and alignment. Instead of discussions, a team accepts automatic formatting.

Prettier’s main task is to separate style from the meaning of a change. A developer writes code, the formatter makes it consistent, and review focuses on logic.

What is inside the repository

The repository contains an intro, input and output examples, a project badge, and contributor material.

Prettier is used in applications, libraries, monorepos, and design systems where multiple people constantly change the same files.

How people usually use it

A normal scenario: add configuration, run formatting before commit or in CI checks, and stop discussing every style difference manually.

For a team, that is especially useful during onboarding. A new contributor does not need to memorize dozens of local conventions; the tool makes code match the accepted style.

Formatting as a project command

This example shows Prettier’s usual role: a command runs across a project and brings files to one style.

Language: Bash
npx prettier . --write
npx prettier . --check

What it feels like in practice

The project’s strength is predictability. It intentionally leaves few options so the formatter does not become a new source of arguments.

Another advantage is broad integration with editors and build processes. Formatting can become an almost invisible part of work.

Limits and careful spots

The limitation is that not everyone likes Prettier’s style. Because the tool is opinionated, it sometimes makes choices a specific developer disagrees with.

Prettier also does not replace a linter. It handles code appearance, but does not need to catch every bug, unsafe pattern, or architecture issue.

Who it fits

Prettier best fits teams willing to trade individual formatting preferences for one automatic style.

In the catalog, Prettier matters as a project that changed development culture: formatting became a tool’s job rather than a source of endless review comments.

In long-term work with a project like this, repeatability matters: the team understands which task it owns, where its responsibility ends, and which updates need attention. Then the repository becomes a clear part of the stack rather than a random dependency without ownership and rules.

In large repositories, Prettier becomes especially visible after the first months of work: change history is cleaner, and formatting edits stop hiding real logic changes.