@biomejs/biome
2.6.8 · 15 Nov 2026MIT OR Apache-2.030.3M / weekRepositoryHomepagenpmAtom feed
2.6.9 is the newest release of 2.x.
In short
6 new22 fixed1 internal
Release note
The section about @biomejs/biome of a note shared by several packages.
Patch Changes
Added the nursery rule
useLayeredStyles, which enforces that style rules are defined within a cascade layer and import rules to import its styles into a cascade layer./* Invalid */ @import 'foo.css'; .my-style { color: red; } /* Valid */ @import 'foo.css' layer(base); @layer base { .my-style { color: red; } }Added the nursery rule
useBetterDomTraversing, which prefers.firstChild,.firstElementChild,.closest(), and merged.querySelector()calls over positional DOM traversal.element.childNodes[0]; element.children[0]; element.parentElement.parentElement; element.querySelector("a").querySelector("b");Fixed #11610, #11611, #11612, #11615, and #11616: Biome no longer fully infers an imported generic declaration just to apply its type arguments, restoring type-aware lint performance for large libraries such as Zod. This improves
useRegexpExec,noFloatingPromises,noMisusedPromises,useNullishCoalescing, andnoUnsafePlusOperands.Fixed #7495:
noUselessConstructornow ignores TypeScript constructors that forward at least one argument tosuper, preserving constructors that narrow the subclass's accepted parameter types. The exemption also applies when the parent and child signatures are identical; JavaScript and zero-argument forwarding behavior are unchanged.Fixed #7076:
useAriaPropsForRoleanduseFocusableInteractiveno longer report non-focusable elements withrole="separator". A separator with an explicittabIndexortabindexstill requiresaria-valuenow.Fixed #6571 so Grit plugins can capture and inspect multiple named import specifiers.
Reduced unnecessary type inference when type-aware lint rules inspect members of namespace imports from libraries such as Zod. Fixed type inference so blanket re-exports do not expose default exports.
Added the nursery rule
noXorAsExponentiation, which reports the bitwise XOR operator^between two decimal integer literals, where the exponentiation operator**was likely intended.const kibibyte = 2 ^ 10; // 8, not 1024
Fixed #7192:
noUnusedPrivateClassMembersnow considers compound assignments such as??=to read and use private class members.Fixed #11672 and #11671 by disabling the experimental capitalized-call and effect-dependency checks in
useReactCompiler, matching their exclusion from upstream's recommended lint preset. Valid calls such asIntl.NumberFormat()and captures of variables declared inside effects no longer produce these diagnostics.Fixed #11653: Astro template suppression comments (
{/* biome-ignore lint: reason */}) now suppress matching HTML lint diagnostics on the following line when full HTML support is enabled.Improved the performance of
useRegexpExec.Fixed the HTML formatter inserting whitespace between adjacent Svelte expressions when their combined length exceeds the line width.
<span> - {head.median - base.median >= 0 ? "+" : "−"} - {formatMs(Math.abs(head.median - base.median))} + {head.median - base.median >= 0 ? "+" : "−"}{formatMs(Math.abs(head.median - base.median))} </span>Fixed #11644:
useHeadingContentno longer reports headings that render their text with a directive:set:htmlandset:textin Astro files,v-htmlandv-textin Vue files.<h1 set:html={heading} /> <h2 set:text={heading}></h2><template> <h1 v-html="heading"></h1> <h2 v-text="heading"></h2> </template>
Improved the performance of Biome Formatter up to ~50% in some cases.
Fixed #6974, where
noUnusedPrivateClassMembersincorrectly reported TypeScript private constructor properties read through object destructuring fromthisas unused.Fixed #11605: Type inference now infers the type of an unannotated callback parameter from the signature of the function the callback is passed to, and honours explicit type arguments on call expressions. This improves type-aware analysis for
noBaseToString,noFloatingPromises,noMisleadingReturnType,noMisusedPromises,noUnnecessaryConditions,noUnsafePlusOperands,noUselessTypeConversion,useArrayFind,useArraySortCompare,useAwaitThenable,useDisposables,useExhaustiveSwitchCases,useIncludes,useNullishCoalescing,useRegexpExec, anduseStringStartsEndsWith. For example,noFloatingPromisescan now detect Promises reached through such parameters:interface Context { doSomething(): Promise<void>; } declare function test(callback: (ctx: Context) => Promise<void>): void; test(async (ctx) => { ctx.doSomething(); // now reported as a floating promise });Fixed parsing of unquoted CSS URLs beginning with
@or!, such asurl(@/assets/icon.svg)andurl(!font.woff2). Preserved escaped and non-ASCII whitespace in raw URLs during formatting.-background-image: url(image\); +background-image: url(image\ );
Added the nursery rule
noUnsafeIframeSandbox, which reportsiframeelements whosesandboxattribute combinesallow-scriptsandallow-same-origin, since that combination lets the embedded document remove its own sandboxing.<iframe src="https://example.com" sandbox="allow-scripts allow-same-origin" />
Added the recommended
noSvelteAtHtmlTagsnursery rule, which reports Svelte{@html}tags that render unescaped HTML.Fixed #6782: GritQL plugins now match captured JSX component names against code snippets such as
React.Fragment.Fixed #11678:
useReactCompilerno longer panics on files that contain non-ASCII characters. This bumps the React Compiler version.Added the nursery Vue-domain rule
useVueBaseImportrule, which enforces importing Vue APIs fromvueinstead of internal@vue/*packages.Fixed
useReactCompilersilently producing no diagnostics in WebAssembly builds, including the playground.Improved linting performance for large CSS and JSON files.
Fixed #7527: suppression actions for diagnostics emitted on comments are now inserted before the diagnostic comment. In particular, suppressing
noTsIgnorenow places thebiome-ignorecomment before@ts-ignore.Fixed #8629, where
noUnusedPrivateClassMembersincorrectly reported used private TypeScript method overload signatures as unused.Improved the performance of
noExcessiveLinesPerFilewhenskipBlankLinesisfalse.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.