DEV Community

Alex Spinov
Alex Spinov

Posted on

Biome Has a Free Linter and Formatter — Replace ESLint + Prettier With One Tool

Your JavaScript Toolchain Is Too Complex

ESLint config: 47 lines. Prettier config: 12 lines. eslint-config-prettier to make them not fight each other. eslint-plugin-import for import sorting. 8 ESLint plugins for React, TypeScript, accessibility.

All to lint and format code.

Biome: One Tool to Replace Them All

Biome is a linter, formatter, and import sorter in a single binary. Written in Rust for speed.

The Speed Difference

ESLint + Prettier on large project: 45 seconds
Biome on same project: 0.5 seconds
Enter fullscreen mode Exit fullscreen mode

90x faster. Your CI pipeline will thank you.

Zero Config Start

npm install --save-dev @biomejs/biome
npx biome init
npx biome check --write .
Enter fullscreen mode Exit fullscreen mode

Three commands. Linting + formatting + import sorting. Done.

What It Replaces

Before After
ESLint Biome
Prettier Biome
eslint-config-prettier Not needed
eslint-plugin-import Biome
@typescript-eslint/parser Biome
@typescript-eslint/eslint-plugin Biome
eslint-plugin-react Biome
eslint-plugin-jsx-a11y Biome

8 packages → 1 package. 200+ lines of config → 10 lines.

Config That Makes Sense

{
  "formatter": {
    "indentStyle": "space",
    "indentWidth": 2,
    "lineWidth": 100
  },
  "linter": {
    "rules": {
      "recommended": true,
      "complexity": {
        "noExcessiveCognitiveComplexity": "warn"
      }
    }
  },
  "organizeImports": {
    "enabled": true
  }
}
Enter fullscreen mode Exit fullscreen mode

Editor Integration

  • VS Code: Official extension with format-on-save
  • IntelliJ/WebStorm: Official plugin
  • Neovim: LSP support
  • Zed: Built-in support

Migration From ESLint

npx biome migrate eslint --write
Enter fullscreen mode Exit fullscreen mode

Biome reads your .eslintrc and generates equivalent biome.json. Most rules have direct equivalents.

What Biome Cannot Do Yet

  • Some ESLint plugins have no equivalent (eslint-plugin-testing-library)
  • Custom rules (ESLint allows custom rules, Biome does not yet)
  • Markdown/CSS formatting (Prettier handles these)

For JavaScript and TypeScript projects, Biome covers 95%+ of what ESLint + Prettier do.

Try It

npm install --save-dev @biomejs/biome
npx biome check --write src/
Enter fullscreen mode Exit fullscreen mode

Need web data? 88+ production scrapers on Apify — Reddit, Trustpilot, Google News. Custom scrapers in 24h: spinov001@gmail.com

Top comments (0)