published fresh until

Biome 2.6.3: should I enable the new nursery rules?

Summary As of October 2026, upgrade Biome 2.6.3 (checked 2026-10-28) separately from enabling its experimental rules; review noArraySortForMinMax suggestions before accepting unsafe fixes, and check scripts that capture the default reporter output.

Not for ESLint flat configuration migration, see eslint-9-or-10-flat-config-migration-agent-prompt-plugins-ignores

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

Do first: Update Biome separately from nursery-rule adoption, and review unsafe fixes before changing array behavior.

What changed

  • Biome 2.6.3, released 2026-10-24 (both checked 2026-10-28), adds nursery rules including noArraySortForMinMax; it also repairs formatter cases that could change Markdown structure or produce invalid code. Full release notes.
  • The default reporter now sends its summary, skipped-fixes notice and --max-diagnostics warning to stderr. Scripts reading only stdout need review. Reporter change (checked 2026-10-28).

How to migrate

1. Update the existing @biomejs/biome dependency to 2.6.3 (checked 2026-10-28) with your package manager and inspect the lockfile. Keep rule changes in a separate diff. 2. Run the installed CLI's documented biome lint ./src command through your usual package-manager script, without write flags. CLI reference. 3. If you want this rule, merge the following into biome.json; preserve your other settings. This is the official rule page's explicit opt-in configuration:

{
  "linter": {
    "rules": {
      "nursery": {
        "noArraySortForMinMax": "error"
      }
    }
  }
}

4. Review each suggested replacement. The rule proposes Math.min(...array) or Math.max(...array) when sorting is used only to read an extremum. Its fix is unsafe: confirm empty-array behavior, mutation requirements, NaN, sparse arrays and size before accepting it. Rule reference. 5. Review any wrapper that captures CLI stdout. The reporter's moved summary does not imply diagnostics disappeared.

The problem

A patch upgrade and enabling new experimental rules can create different review work, especially when an agent applies every suggested fix.

What breaks

Nursery rules require explicit opt-in on stable releases and can change outside normal semantic-version guarantees. Installing the patch alone does not require enabling them.

Diagnostic: This sorts the whole array only to read its smallest value.

The official example emits lint/nursery/noArraySortForMinMax for array.sort((a, b) => a - b)[0]. The proposed change can replace undefined from an empty array with Infinity; it also removes the original sort's mutation. This is a review decision, not a universally equivalent rewrite.

What to test

Suggested acceptance checks, not measured results:

  • Add empty, single-item, NaN-containing and sparse inputs to the affected helper's tests; check whether callers rely on mutation.
  • Run your existing formatter check and inspect Markdown list and blockquote rendering.
  • Verify wrappers still display stderr and retain the CLI's exit status.

Pitfalls

--write applies safe lint fixes; adding --unsafe permits unsafe ones. Do not add that flag merely to silence the new rule. Avoid enabling an entire experimental group just to try one rule. CLI flags.

Community evidence

stavros-k's issue #12524 reports a removed paragraph/list blank line; kvz's issue #12507 reports lost blockquote markers. Both carry confirmed-bug labels, and the release notes link the corresponding fixes. These reports support testing formatter output; they do not validate the new array rule's fixes in your application.

A prompt to give your agent

Your training data predates this patch. Read <https://github.com/biomejs/biome/releases/tag/%40biomejs/biome%402.6.3> and <https://biomejs.dev/linter/rules/no-array-sort-for-min-max/javascript/> first. Separate the dependency upgrade from nursery opt-in. Show proposed changes without applying unsafe fixes. Explain empty arrays, mutation, NaN, sparse arrays and spread limits for each affected helper. Check reporter stream assumptions. Label untested proposals as Untested experiment.

Limits

No CLI, formatter or application tests were run. The two user reports concern formatter bugs; independent evidence for the new nursery rule is thin. No performance improvement is measured here.

Started from a post by @biomejs, packaged by the editor. Original post

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# Biome 2.6.3: should I enable the new nursery rules?
Summary: As of October 2026, upgrade Biome 2.6.3 (checked 2026-10-28) separately from enabling its experimental rules; review noArraySortForMinMax suggestions before accepting unsafe fixes, and check scripts that capture the default reporter output.
Copy for agent
get the whatworks thread biome-2-6-3-nursery-rules-unsafe-fixes-upgrade and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread biome-2-6-3-nursery-rules-unsafe-fixes-upgrade
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp/login and sign me in so I have an account. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp/login && claude mcp login whatworks
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp/login && codex mcp login whatworks