Getting Started with Biome JS

Published: 9/28/2025

Background

For documentation, see the Biome website.

Why use Biome? Add this at end, and prefer tl;dr style?

Prerequisites

Needed, or just assume people know why they'd want Biome.js?

Installation

  1. Install the package:

    pnpm add --save-dev @biomejs/biome
    
  2. Create a basic configuration file:

    npx biome init
    
  3. Add the following scripts to your package.json scripts section:

    "scripts": {
      ...
      "format": "biome format",
      "format:fix": "biome format --write",
      "lint": "biome lint",
      "lint:fix": "biome lint --write",
      "check": "biome check",
      "check:fix": "biome check --write"
    }
    

Usage

pnpm run format         # print formatting errors
pnpm run format:fix     # fix formatting errors
pnpm run lint           # print linting errors
pnpm run lint:fix       # fix linting errors
pnpm run check          # print all errors
pnpm run check:fix      # fix all errors

Optional Extras

  1. Install the Biome Extension for VS Code