Skip to content

Conversation

@janhesters
Copy link
Collaborator

Summary

  • Remove ESLint, eslint-config-prettier, eslint-plugin-prettier, and Prettier
  • Add Biome v2.3.12 for linting and formatting
  • Update npm scripts (lint, format, format:check) to use Biome commands
  • Apply Biome formatting and lint fixes across codebase
  • Add .claude/ to .gitignore

Configuration notes

  • Added override to allow any in TypeScript declaration files (.d.ts)
  • Disabled useNodejsImportProtocol rule for compatibility with existing imports

Test plan

  • All unit tests pass (npm run test:unit)
  • Lint passes (npm run lint)
  • Type check passes (npm run typecheck)
  • Pre-commit and pre-push hooks work correctly

🤖 Generated with Claude Code

@janhesters janhesters force-pushed the chore/replace-eslint-with-biome branch from 39844a2 to 0b89842 Compare January 26, 2026 08:09
@ericelliott
Copy link
Collaborator

@cursoragent please /review - use web search and look at the diff when we run lint and formatting on the codebase - do we lose any useful formatting or any important style rules or bug catching capabilities with this migration?

@cursor
Copy link

cursor bot commented Jan 26, 2026

🔬 Review Complete: ESLint/Prettier → Biome Migration

I've conducted a comprehensive code review of this PR, examining the diff, comparing linter capabilities, and analyzing the impact. Here's what I found:

Verdict: APPROVE - Migration is Safe and Beneficial

Key Findings:

  1. Better Bug Detection 🎯

    • Biome found 21 real code quality issues that the old ESLint config missed
    • Unused variables (10+ instances across lib/, release.js)
    • Unused imports (2 test files)
    • Unused function parameters (6 in release.js error handlers)
    • Template literal opportunities
  2. No Functionality Lost

    • Old ESLint config was minimal (only ran Prettier formatting)
    • No custom ESLint rules were in use
    • No ESLint plugins were configured
    • Biome provides 200+ lint rules vs. the old setup's ~0 actual lint rules
  3. Formatting Changes 📐

    • Import ordering: Now sorted (Node built-ins → packages → local)
    • Object key sorting: Alphabetized (no runtime impact, debatable style preference)
    • Template literals: Preferred over string concatenation
    • JSON formatting: Compact arrays for readability
  4. Performance Gains 🚀

    • ~10-20x faster linting/formatting (Rust vs. JavaScript)
    • 75% fewer dependencies (1 vs. 4 packages)
    • Lower memory footprint

📋 Complete Review Document

I've created a detailed review at biome-migration-review.md covering:

  • Diff analysis of all 49 changed files
  • Line-by-line comparison of old vs. new configs
  • Security assessment
  • Rule coverage comparison
  • Specific examples of improvements
  • Optional follow-up recommendations

💡 Optional Follow-Up

The 21 warnings Biome found are real issues worth fixing (unused code cleanup). They're not bugs, but they improve code clarity. Can be addressed with:

npm run lint -- --write --unsafe  # Auto-fix safe issues
# Then manually review remaining warnings

Bottom line: This migration strengthens the codebase with better linting, catches real issues, and speeds up the development workflow. No downside detected.

Open in Cursor Open in Web

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR replaces ESLint and Prettier with Biome v2.3.12 as the project's linting and formatting tool. The changes include removing the old tooling dependencies, adding Biome configuration, updating npm scripts, and applying Biome's formatting rules across the entire codebase. All existing tests pass and the migration introduces no functional changes.

Changes:

  • Replaced ESLint, eslint-config-prettier, eslint-plugin-prettier, and Prettier with Biome v2.3.12
  • Updated npm scripts to use Biome commands for linting and formatting
  • Applied Biome formatting and linting rules across the codebase (import organization, object property sorting, forEach to for...of conversion)

Reviewed changes

Copilot reviewed 40 out of 49 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
package.json Replaced ESLint/Prettier dependencies with Biome, updated lint/format scripts
package-lock.json Updated lockfile with Biome dependencies and removed ESLint/Prettier
biome.json Added Biome configuration with linting rules and formatting preferences
eslint.config.mjs Removed ESLint configuration file
.gitignore Added .claude/ directory to ignore list
tsconfig.json Reformatted with alphabetically sorted properties
vitest.config.js Reformatted with reordered properties
.release-it.json Reformatted with reordered properties
utils/index.js Imports reordered alphabetically
utils/index.d.ts Function signatures reformatted with proper line breaks
src/server/**/*.js Imports reordered, object properties sorted alphabetically
src/server/**/*.d.ts Function signatures reformatted
lib/**/*.js Imports reordered, object properties sorted, forEach to for...of conversion
lib/**/*.d.ts Function signatures reformatted
bin/aidd.js Imports reordered, object properties sorted
ai/rules/sudolang/index.md Added index file for sudolang directory
ai/rules/index.md Updated to include sudolang directory reference
ai/rules/user-testing.test.js Test assertion properties reordered alphabetically
release.js Object properties sorted alphabetically

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

import { fileURLToPath } from "url";
import fs from "fs-extra";
import { assert } from "riteway/vitest";
import { afterEach, beforeEach, describe, test } from "vitest";
Copy link

Copilot AI Jan 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import beforeEach.

Suggested change
import { afterEach, beforeEach, describe, test } from "vitest";
import { afterEach, describe, test } from "vitest";

Copilot uses AI. Check for mistakes.
import { describe, test, beforeEach, vi } from "vitest";
import { assert } from "riteway/vitest";
import { createRoute, convertMiddleware } from "./create-route.js";
import { beforeEach, describe, test, vi } from "vitest";
Copy link

Copilot AI Jan 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import beforeEach.

Suggested change
import { beforeEach, describe, test, vi } from "vitest";
import { describe, test, vi } from "vitest";

Copilot uses AI. Check for mistakes.
- Remove ESLint, eslint-config-prettier, eslint-plugin-prettier, and Prettier
- Add Biome v2.3.12 for linting and formatting
- Update npm scripts to use Biome commands
- Add override to allow `any` in TypeScript declaration files
- Disable key sorting for test files to preserve riteway assert order
- Disable `useNodejsImportProtocol` rule for compatibility
- Add `.claude/` to .gitignore

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@janhesters janhesters force-pushed the chore/replace-eslint-with-biome branch from ecd83ce to 2892991 Compare January 27, 2026 09:45
@janhesters janhesters self-assigned this Jan 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants