Keep formatting consistent across the extension codebase with minimal manual effort. Prettier runs from scripts, editor integration, and CI rather than inside the Extension.js build pipeline.
| Capability | What it gives you |
|---|---|
| Consistent formatting | One shared style for JS, TS, JSON, CSS, and Markdown |
| Script and editor workflow | Format on save locally and enforce in CI |
| Lint conflict reduction | Pair with eslint-config-prettier to avoid rule overlap |
| Low-maintenance defaults | Adopt a stable baseline with minimal config |
Preconfigured formatter setup for new projects.

Repository: examples/new-config-prettier
Install Prettier:
Create a config file (for example .prettierrc):
Run Prettier from scripts or manually:
If no format script exists yet:
To avoid formatting-rule conflicts in ESLint, install:
Then add eslint-config-prettier in your ESLint config chain so ESLint defers formatting concerns to Prettier.
--check in CI and --write locally.