Open
Conversation
d2cb659 to
4b5a3dc
Compare
6f2be8d to
1762fa5
Compare
1762fa5 to
d7f5e76
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or setup this action to publish automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.
Releases
@biomejs/biome@2.4.5
Patch Changes
#9184
49c8fdeThanks @chocky335! - Improved plugin performance by batching all plugins into a single syntax visitor with a kind-to-plugin lookup map, reducing per-node dispatch overhead from O(N) to O(1) where N is the number of plugins.#9221
4612133Thanks @ematipico! - Fixed an issue where the JSON reporter didn't contain the duration of the command.#9178
101b3bbThanks @Bertie690! - Fixed #9172 and #9168:Biome now considers more constructs as valid test assertions.
Previously,
assert,expectTypeOfandassertTypewere not recognized as valid assertions by Biome's linting rules, producing false positives in
lint/nursery/useExpectand other similar rules.Now, these rules will no longer produce errors in test cases that used these constructs instead of
expect:#9173
32dad2dThanks @dyc3! - Added parsing support for Svelte's new comments-in-tags feature.The HTML parser will now accept JS style comments in tags in Svelte files.
#8952
1d2ca15Thanks @pkallos! - Added the nursery ruleuseNullishCoalescing. This rule suggests using the nullish coalescing operator (??) instead of logical OR (||) when the left operand may be nullish. This prevents bugs where falsy values like0,'', orfalseare incorrectly treated as missing. Addresses #8043#9243
1992a85Thanks @Netail! - Fixed #7813: improved the diagnostic of the ruleuseExhaustiveDependencies. The diagnostic now shows the name of the variable to add to the dependency array.#9063
3d0648fThanks @taga3s! - Added the nursery rulenoVueRefAsOperand. This rule disallows cases where a ref is used as an operand.The following code is now flagged:
#9259
96939c0Thanks @ematipico! - Fixed CSS formatter incorrectly collapsing selectors when a BOM (Byte Order Mark) character is present at the start of the file. The formatter now correctly preserves line breaks between comments and selectors in BOM-prefixed CSS files, matching Prettier's behavior.#9251
59e33fbThanks @ematipico! - Fixed #9249: The CSS formatter no longer incorrectly breaks ratio values (like1 / -1) across lines when followed by comments.#9215
b2619a1Thanks @FrederickStempfle! - Fixed #9189:biome ciin GitHub Actions now correctly disables colors so that::error/::warningworkflow commands are not wrapped in ANSI escape codes.#9223
5b9da81Thanks @ematipico! - Fixed an issue where the JSON reporter didn't write output to a file when--reporter-filewas specified. The output is now correctly written to the specified file instead of always going to stdout.#9154
c487e54Thanks @abossenbroek! - Fixed #9115: ThenoPlaywrightMissingAwaitrule no longer produces false positives on jest-dom matchers liketoBeVisible,toBeChecked,toHaveAttribute, etc. For matchers shared between Playwright and jest-dom, the rule now checks whetherexpect()'s argument is a Playwright locator or page object before flagging. Added semantic variable resolution so that extracted Playwright locators (e.g.const loc = page.locator('.item'); expect(loc).toBeVisible()) are still correctly flagged.#9254
f7bf12bThanks @ematipico! - Fixed #8842: The CSS formatter now correctly formats@container scroll-state()without adding an unwanted space between the function name and opening parenthesis.#9211
2d0b8e6Thanks @ematipico! - Fixed #7905. Improved the accuracy of type-aware lint rules when analyzing re-exported functions and values.Previously, when a binding was imported from another module, its type was not correctly inferred during the type analysis phase. This caused type-aware lint rules to fail to detect issues when working with re-exported imports.
The following rules now correctly handle re-exported imports:
useAwaitThenablenoFloatingPromisesnoMisusedPromisesuseArraySortCompareExample of now-working detection:
#8934
b49707cThanks @tim-we! - Fixed #8265: Biome now correctly detects test framework calls that use three arguments (label, options, callback) (e.g.,describe("foo", { retry: 2 }, () => {})). This fixes both formatting and thenoDuplicateTestHookslint rule for test frameworks like Vitest.#9191
688fd34Thanks @dyc3! - Fixed #9180: fixed a panic caused by an interaction betweennoRedundantUseStrictand the formatter#9048
9bbdf4dThanks @ff1451! - Added the nursery ruleuseNamedCaptureGroup.The rule enforces using named capture groups in regular expressions instead of numbered ones. It supports both regex literals and
RegExpconstructor calls.#9255
9b6685bThanks @ematipico! - Fixed#9234, where some nursery rules panicked when they were configured with the optionlevelwithout the correspondingoptions.#9266
84935a4Thanks @dyc3! - Fixed #9250:noVueDuplicateKeyswill no longer flag keys underwatch, preventing false positives.#9056
1f2fe2eThanks @ruidosujeira! - Added the nursery ruleuseArraySometo prefer.some()over verbose existence checks likefilter(...).length > 0andfindIndex(...) !== -1, with suggestions forfind/findLastexistence checks. This also applies to ES2025 iterator helpers such asIterator.prototype.find.#9163
f87acf6Thanks @JUSTIVE! - Addedgraphqlto valid embedded graphql template tags inside JavaScript files, when the featurejavascript.experimentalEmbeddedSnippetsEnabledis enabled. This allows proper support for graphql tags used in RelayJS.Now, code snippets like the following are correctly formatted and limited:
@biomejs/backend-jsonrpc@2.0.42
@biomejs/cli-darwin-arm64@2.4.5
@biomejs/cli-darwin-x64@2.4.5
@biomejs/cli-linux-arm64@2.4.5
@biomejs/cli-linux-arm64-musl@2.4.5
@biomejs/cli-linux-x64@2.4.5
@biomejs/cli-linux-x64-musl@2.4.5
@biomejs/cli-win32-arm64@2.4.5
@biomejs/cli-win32-x64@2.4.5
@biomejs/wasm-bundler@2.4.5
@biomejs/wasm-nodejs@2.4.5
@biomejs/wasm-web@2.4.5