-
-
Notifications
You must be signed in to change notification settings - Fork 438
Commit 14227ee
authored
chore(deps): update dependency biome to v2 (#1109)
This PR contains the following updates:
| Package | Update | Change |
|---|---|---|
| [biome](https://redirect.github.com/biomejs/biome) | major | `1.9.4`
-> `2.1.3` |
---
### Release Notes
<details>
<summary>biomejs/biome (biome)</summary>
###
[`v2.1.3`](https://redirect.github.com/biomejs/biome/releases/tag/%40biomejs/biome%402.1.3):
Biome CLI v2.1.3
#### 2.1.3
##### Patch Changes
- [#​7057](https://redirect.github.com/biomejs/biome/pull/7057)
[`634a667`](https://redirect.github.com/biomejs/biome/commit/634a667ac8e9f74a4633895eab4bd4695ffffa1d)
Thanks [@​mdevils](https://redirect.github.com/mdevils)! - Added
the rule
[`noVueReservedKeys`](https://biomejs.dev/linter/rules/no-vue-reserved-keys/),
which prevents the use of reserved Vue keys.
It prevents the use of Vue reserved keys such as those starting with `#
@​biomejs/biome (like `$el`, `$data`, `$props`) and keys starting
with `\_\` in data properties, which can cause conflicts and unexpected
behavior in Vue components.
##### Invalid example
```vue
<script>
export default {
data: {
$el: "",
_foo: "bar",
},
};
</script>
```
```vue
<script>
export default {
computed: {
$data() {
return this.someData;
},
},
};
</script>
```
##### Valid examples
```vue
<script>
export default {
data() {
return {
message: "Hello Vue!",
count: 0,
};
},
};
</script>
```
```vue
<script>
export default {
computed: {
displayMessage() {
return this.message;
},
},
};
</script>
```
- [#​6941](https://redirect.github.com/biomejs/biome/pull/6941)
[`734d708`](https://redirect.github.com/biomejs/biome/commit/734d708bd84f32d72e5972cc27c194d5da46a3c0)
Thanks
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562)! -
Added `@eslint-react/no-nested-component-definitions` as a rule source
for `noNestedComponentDefinitions`. Now it will get picked up by `biome
migrate --eslint`.
- [#​6463](https://redirect.github.com/biomejs/biome/pull/6463)
[`0a16d54`](https://redirect.github.com/biomejs/biome/commit/0a16d54c2cffbf13c5144b53021923734f1c234e)
Thanks
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562)! -
Fixed a website link for the `useComponentExportOnlyModules` linter rule
to point to the correct URL.
- [#​6944](https://redirect.github.com/biomejs/biome/pull/6944)
[`e53f2fe`](https://redirect.github.com/biomejs/biome/commit/e53f2fe03827a8dcad2184178ecfaee0e35af992)
Thanks [@​sterliakov](https://redirect.github.com/sterliakov)! -
Fixed
[#​6910](https://redirect.github.com/biomejs/biome/issues/6910):
Biome now ignores type casts and assertions when evaluating numbers for
`noMagicNumbers` rule.
- [#​6991](https://redirect.github.com/biomejs/biome/pull/6991)
[`476cd55`](https://redirect.github.com/biomejs/biome/commit/476cd55e4e5b1b03335e14c65ad01b2bbb4b8d42)
Thanks [@​denbezrukov](https://redirect.github.com/denbezrukov)! -
Fixed
[#​6973](https://redirect.github.com/biomejs/biome/issues/6973):
Add support for parsing the :active-view-transition-type() pseudo-class
```css
:active-view-transition-type(first second) {
}
```
- [#​6992](https://redirect.github.com/biomejs/biome/pull/6992)
[`0b1e194`](https://redirect.github.com/biomejs/biome/commit/0b1e19474e323c7354fccff0c5654d47024c7b91)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Added a new JSON rule called `noQuickfixBiome`, which disallow the use
of code action `quickfix.biome` inside code editor settings.
- [#​6943](https://redirect.github.com/biomejs/biome/pull/6943)
[`249306d`](https://redirect.github.com/biomejs/biome/commit/249306db32b6a912f39d2c88a1b0d702b8b97a9b)
Thanks
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562)! -
Fixed `@vitest/eslint-plugin` source url.
- [#​6947](https://redirect.github.com/biomejs/biome/pull/6947)
[`4c7ed0f`](https://redirect.github.com/biomejs/biome/commit/4c7ed0fda858424a21fb1766270aaa74838a46a1)
Thanks
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562)! -
Fixed ESLint migration for the rule `prefer-for` from
`eslint-plugin-solid` to Biome's `useForComponent`.
- [#​6976](https://redirect.github.com/biomejs/biome/pull/6976)
[`72ebadc`](https://redirect.github.com/biomejs/biome/commit/72ebadce0e192932d237d9a31c45cb230c8bbd91)
Thanks [@​siketyan](https://redirect.github.com/siketyan)! - Fixed
[#​6692](https://redirect.github.com/biomejs/biome/issues/6692):
The rules `noUnusedVariables` and `noUnusedFunctionParameters` no longer
cause an infinite loop when the suggested name is not applicable (e.g.
the suggested name is already declared in the scope).
- [#​6990](https://redirect.github.com/biomejs/biome/pull/6990)
[`333f5d0`](https://redirect.github.com/biomejs/biome/commit/333f5d0a11dc1b2c029c657905bc73d3daf72477)
Thanks
[@​rvanlaarhoven](https://redirect.github.com/rvanlaarhoven)! -
Fixed the documentation URL for `lint/correctness/noUnknownPseudoClass`
- [#​7000](https://redirect.github.com/biomejs/biome/pull/7000)
[`4021165`](https://redirect.github.com/biomejs/biome/commit/402116575ef570da02ccbce521645a3975b3e8ce)
Thanks [@​harxki](https://redirect.github.com/harxki)! - Fixed
[#​6795](https://redirect.github.com/biomejs/biome/issues/6795):
`noUnassignedVariables` now correctly recognizes variables used in JSX
`ref` attributes.
- [#​7044](https://redirect.github.com/biomejs/biome/pull/7044)
[`b091ddf`](https://redirect.github.com/biomejs/biome/commit/b091ddf73d323a6929b9601f05ede7e91e4d4cbb)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed
[#​6622](https://redirect.github.com/biomejs/biome/issues/6622),
now the rule `useSemanticElements` works for JSX self-closing elements
too.
- [#​7014](https://redirect.github.com/biomejs/biome/pull/7014)
[`c4864e8`](https://redirect.github.com/biomejs/biome/commit/c4864e85ebbb1bbfbb8274c59bb6af9413d8f157)
Thanks [@​siketyan](https://redirect.github.com/siketyan)! - Fixed
[#​6516](https://redirect.github.com/biomejs/biome/issues/6516):
The `biome migrate` command no longer break the member list with
trailing comments.
- [#​6979](https://redirect.github.com/biomejs/biome/pull/6979)
[`29cb6da`](https://redirect.github.com/biomejs/biome/commit/29cb6da9a1e8f20af59f5e681b9d2aa1a23e8b27)
Thanks [@​unvalley](https://redirect.github.com/unvalley)! - Fixed
[#​6767](https://redirect.github.com/biomejs/biome/issues/6767):
`useSortedClasses` now correctly removes leading and trailing whitespace
in className.
Previously, trailing spaces in className were not fully removed.
```jsx
// Think we have this code:
<div className="text-sm font-bold " />
// Before: applied fix, but a trailing space was preserved
<div className="font-bold text-sm " />
// After: applied fix, trailing spaces removed
<div className="font-bold text-sm" />
```
- [#​7055](https://redirect.github.com/biomejs/biome/pull/7055)
[`ee4828d`](https://redirect.github.com/biomejs/biome/commit/ee4828da9be5898c67b7feabfaaa296ad172109f)
Thanks [@​dyc3](https://redirect.github.com/dyc3)! - Added the
nursery rule
[`useReactFunctionComponents`](https://biomejs.dev/linter/rules/use-react-function-components/).
This rule enforces the preference to use function components instead of
class components.
Valid:
```jsx
function Foo() {
return <div>Hello, world!</div>;
}
```
Invalid:
```jsx
class Foo extends React.Component {
render() {
return <div>Hello, world!</div>;
}
}
```
- [#​6924](https://redirect.github.com/biomejs/biome/pull/6924)
[`2d21be9`](https://redirect.github.com/biomejs/biome/commit/2d21be9437fd77a1c534a1ea156d9a9421c17d30)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed
[#​113](https://redirect.github.com/biomejs/biome-zed/issues/113),
where the Biome Language Server didn't correctly update the diagnostics
when the configuration file is modified in the editor. Now the
diagnostics are correctly updated every time the configuration file is
modified and saved.
- [#​6931](https://redirect.github.com/biomejs/biome/pull/6931)
[`e6b2380`](https://redirect.github.com/biomejs/biome/commit/e6b238063f92bc95d951e3a78dac42408d0814c0)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6915](https://redirect.github.com/biomejs/biome/issues/6915):
`useHookAtTopLevel` no longer hangs when rules call themselves
recursively.
- [#​7012](https://redirect.github.com/biomejs/biome/pull/7012)
[`01c0ab4`](https://redirect.github.com/biomejs/biome/commit/01c0ab43ad7785e093e5069dda1d5e6969958bf8)
Thanks [@​siketyan](https://redirect.github.com/siketyan)! - Fixed
[#​5837](https://redirect.github.com/biomejs/biome/issues/5837):
Invalid suppression comments such as `biome-ignore-all-start` or
`biome-ignore-all-end` no longer causes a panic.
- [#​6949](https://redirect.github.com/biomejs/biome/pull/6949)
[`48462f8`](https://redirect.github.com/biomejs/biome/commit/48462f81ba4e98a95236365a5f9759fc41c045d7)
Thanks [@​fireairforce](https://redirect.github.com/fireairforce)!
- Support parse `import defer`(which is a [stage3
proposal](https://redirect.github.com/tc39/proposal-defer-import-eval)).
The syntax look like this:
```ts
import defer * as foo from "<specifier>";
```
- [#​6938](https://redirect.github.com/biomejs/biome/pull/6938)
[`5feb5a6`](https://redirect.github.com/biomejs/biome/commit/5feb5a675adb246b04b1540cba16ff1c5fd49cb1)
Thanks
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)!
- Fixed
[#​6919](https://redirect.github.com/biomejs/biome/issues/6919)
and
[#​6920](https://redirect.github.com/biomejs/biome/issues/6920):
`useReadonlyClassProperties` now does checks for mutations in async
class methods.
Example:
```typescript
class Counter3 {
private counter: number;
async count() {
this.counter = 1;
const counterString = `${this.counter++}`;
}
}
```
- [#​6942](https://redirect.github.com/biomejs/biome/pull/6942)
[`cfda528`](https://redirect.github.com/biomejs/biome/commit/cfda528169dcceb8422a0488b39a3b1b27a24645)
Thanks [@​sterliakov](https://redirect.github.com/sterliakov)! -
Fixed
[#​6939](https://redirect.github.com/biomejs/biome/issues/6939).
Biome now understands `this` binding in classes outside of methods.
#### What's Changed
- docs: explain how to document options by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6916](https://redirect.github.com/biomejs/biome/pull/6916)
- chore: fix changelog by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6917](https://redirect.github.com/biomejs/biome/pull/6917)
- fix: update `useComponentExportOnlyModules` website link by
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562) in
[https://github.com/biomejs/biome/pull/6463](https://redirect.github.com/biomejs/biome/pull/6463)
- fix(lsp): update diagnostics on watched files by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6924](https://redirect.github.com/biomejs/biome/pull/6924)
- fix(linter): fix recursive hooks by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6931](https://redirect.github.com/biomejs/biome/pull/6931)
- perf: introduce `Path` type by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6935](https://redirect.github.com/biomejs/biome/pull/6935)
- ci: add French, Spanish and Ukrainian to labeler by
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562) in
[https://github.com/biomejs/biome/pull/6926](https://redirect.github.com/biomejs/biome/pull/6926)
- refactor: add `no-nested-component-definitions` rule to eslint
migration by
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562) in
[https://github.com/biomejs/biome/pull/6941](https://redirect.github.com/biomejs/biome/pull/6941)
- fix: typo `perfer-for` → `prefer-for` by
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562) in
[https://github.com/biomejs/biome/pull/6947](https://redirect.github.com/biomejs/biome/pull/6947)
- fix(core): fix type inference of `this` by
[@​sterliakov](https://redirect.github.com/sterliakov) in
[https://github.com/biomejs/biome/pull/6942](https://redirect.github.com/biomejs/biome/pull/6942)
- fix(biome\_js\_analyze): ignore `as const` and similar wrappers in
`noMagicNumbers` rule by
[@​sterliakov](https://redirect.github.com/sterliakov) in
[https://github.com/biomejs/biome/pull/6944](https://redirect.github.com/biomejs/biome/pull/6944)
- fix: typo `@vitest/eslint-plugin` source url by
[@​JamBalaya56562](https://redirect.github.com/JamBalaya56562) in
[https://github.com/biomejs/biome/pull/6943](https://redirect.github.com/biomejs/biome/pull/6943)
- chore(deps): update github-actions by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6954](https://redirect.github.com/biomejs/biome/pull/6954)4
- perf: shrink `Text` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6946](https://redirect.github.com/biomejs/biome/pull/6946)
- fix(deps): update rust crate roaring to 0.11.1 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6959](https://redirect.github.com/biomejs/biome/pull/6959)9
- chore(deps): update typescript-eslint monorepo to v8.37.0 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6960](https://redirect.github.com/biomejs/biome/pull/6960)0
- chore(deps): update rust crate serde\_json to 1.0.141 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6957](https://redirect.github.com/biomejs/biome/pull/6957)7
- chore(deps): update dependency
[@​types/node](https://redirect.github.com/types/node) to v22.16.5
by [@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6956](https://redirect.github.com/biomejs/biome/pull/6956)6
- feat(biome-js-analyze): expanded support for
useReadonlyClassProperties to cover async class methods too by
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)
in
[https://github.com/biomejs/biome/pull/6938](https://redirect.github.com/biomejs/biome/pull/6938)
- chore(deps): update dependency
[@​types/node](https://redirect.github.com/types/node) to v22.16.5
by [@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6955](https://redirect.github.com/biomejs/biome/pull/6955)5
- feat(parser): support import defer by
[@​fireairforce](https://redirect.github.com/fireairforce) in
[https://github.com/biomejs/biome/pull/6949](https://redirect.github.com/biomejs/biome/pull/6949)
- chore: split `Type` from `TypeData` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6963](https://redirect.github.com/biomejs/biome/pull/6963)
- feat(yaml\_parser): parse flow constructs by
[@​vohoanglong0107](https://redirect.github.com/vohoanglong0107)
in
[https://github.com/biomejs/biome/pull/6961](https://redirect.github.com/biomejs/biome/pull/6961)
- fix: remove infinite loop on `function A(A) {}` by
[@​siketyan](https://redirect.github.com/siketyan) in
[https://github.com/biomejs/biome/pull/6976](https://redirect.github.com/biomejs/biome/pull/6976)
- feat(parse): add tailwind grammar by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6978](https://redirect.github.com/biomejs/biome/pull/6978)
- fix(deps): update
[@​biomejs](https://redirect.github.com/biomejs) packages (major)
by [@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6962](https://redirect.github.com/biomejs/biome/pull/6962)2
- feat(parse): add tailwind parser by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6980](https://redirect.github.com/biomejs/biome/pull/6980)
- fix: update documentation URL for `noUnknownPseudoClass` by
[@​rvanlaarhoven](https://redirect.github.com/rvanlaarhoven) in
[https://github.com/biomejs/biome/pull/6990](https://redirect.github.com/biomejs/biome/pull/6990)
- fix(lint/useSortedClasses): remove leading and trailing whitespaces by
[@​unvalley](https://redirect.github.com/unvalley) in
[https://github.com/biomejs/biome/pull/6979](https://redirect.github.com/biomejs/biome/pull/6979)
- feat(json/analyze): rule `noQuickfixBiome` by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6992](https://redirect.github.com/biomejs/biome/pull/6992)
- chore: update generated code from analyzer codegen by
[@​harxki](https://redirect.github.com/harxki) in
[https://github.com/biomejs/biome/pull/7001](https://redirect.github.com/biomejs/biome/pull/7001)
- refactor(formatter): specialised verbatim formatting by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/7002](https://redirect.github.com/biomejs/biome/pull/7002)
- fix(css\_parser): add active-view-transition-type()
([#​6973](https://redirect.github.com/biomejs/biome/issues/6973))
by [@​denbezrukov](https://redirect.github.com/denbezrukov) in
[https://github.com/biomejs/biome/pull/6991](https://redirect.github.com/biomejs/biome/pull/6991)
- fix(suppression): invalid suppression comments should not cause a
panic by [@​siketyan](https://redirect.github.com/siketyan) in
[https://github.com/biomejs/biome/pull/7012](https://redirect.github.com/biomejs/biome/pull/7012)
- fix(migrate): transfer comments to the separator by
[@​siketyan](https://redirect.github.com/siketyan) in
[https://github.com/biomejs/biome/pull/7014](https://redirect.github.com/biomejs/biome/pull/7014)
- test(biome-js-analyze): add tests to cover tests to cover ??=, ||=,
&&= by
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)
in
[https://github.com/biomejs/biome/pull/7010](https://redirect.github.com/biomejs/biome/pull/7010)
- fix(lint/noUnassignedVariables): handle JSX ref attribute assignments
by [@​harxki](https://redirect.github.com/harxki) in
[https://github.com/biomejs/biome/pull/7000](https://redirect.github.com/biomejs/biome/pull/7000)
- ci: use depot cargo in the PR workflow by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/7045](https://redirect.github.com/biomejs/biome/pull/7045)
- Revert "ci: use depot cargo in the PR workflow" by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/7046](https://redirect.github.com/biomejs/biome/pull/7046)
- fix(lint): `useSemanticElements` self-closing elements by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/7044](https://redirect.github.com/biomejs/biome/pull/7044)
- chore(deps): update rust:1.88.0-bullseye docker digest to
[`b315f98`](https://redirect.github.com/biomejs/biome/commit/b315f98) by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/7043](https://redirect.github.com/biomejs/biome/pull/7043)3
- ci: make it so windows devs don't get lints that don't show up on
linux/macos by [@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/7003](https://redirect.github.com/biomejs/biome/pull/7003)
- docs: update analyzer CONTRIBUTING.md by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/7056](https://redirect.github.com/biomejs/biome/pull/7056)
- refactor(format): use specialised tokens by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/7052](https://redirect.github.com/biomejs/biome/pull/7052)
- feat(lint): implement `noVueReservedKeys` rule by
[@​mdevils](https://redirect.github.com/mdevils) in
[https://github.com/biomejs/biome/pull/7057](https://redirect.github.com/biomejs/biome/pull/7057)
- feat(analyze/js): add useReactFunctionComponents rule by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/7055](https://redirect.github.com/biomejs/biome/pull/7055)
- ci: release by
[@​github-actions](https://redirect.github.com/github-actions)\[bot]
in[https://github.com/biomejs/biome/pull/6927](https://redirect.github.com/biomejs/biome/pull/6927)7
#### New Contributors
- [@​rvanlaarhoven](https://redirect.github.com/rvanlaarhoven)
made their first contribution in
[https://github.com/biomejs/biome/pull/6990](https://redirect.github.com/biomejs/biome/pull/6990)
- [@​harxki](https://redirect.github.com/harxki) made their first
contribution in
[https://github.com/biomejs/biome/pull/7001](https://redirect.github.com/biomejs/biome/pull/7001)
**Full Changelog**:
https://github.com/biomejs/biome/compare/[@​biomejs/biome](https://redirect.github.com/biomejs/biome)@​2.1.2...[@​biomejs/biome](https://redirect.github.com/biomejs/biome)@​2.1.3
###
[`v2.1.2`](https://redirect.github.com/biomejs/biome/releases/tag/%40biomejs/biome%402.1.2):
Biome CLI v2.1.2
#### 2.1.2
##### Patch Changes
- [#​6865](https://redirect.github.com/biomejs/biome/pull/6865)
[`b35bf64`](https://redirect.github.com/biomejs/biome/commit/b35bf6448fb1950c922e627254588e96748e287f)
Thanks [@​denbezrukov](https://redirect.github.com/denbezrukov)! -
Fix
[#​6485](https://redirect.github.com/biomejs/biome/issues/6485):
Handle multiple semicolons correctly in blocks
([#​6485](https://redirect.github.com/biomejs/biome/issues/6485))
```css
div {
box-sizing: border-box;
color: red;
}
```
- [#​6798](https://redirect.github.com/biomejs/biome/pull/6798)
[`3579ffa`](https://redirect.github.com/biomejs/biome/commit/3579ffaae4e86835b001fee4ab7dd8aabb03ae54)
Thanks [@​dyc3](https://redirect.github.com/dyc3)! - Fixed
[#​6762](https://redirect.github.com/biomejs/biome/issues/6762),
Biome now knows that `~/.config/zed/settings.json` and
`~/.config/Code/User/settings.json` allows comments by default.
- [#​6839](https://redirect.github.com/biomejs/biome/pull/6839)
[`4cd62d8`](https://redirect.github.com/biomejs/biome/commit/4cd62d8ae2e5cb24d6f308e05b38003486294548)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed
[#​6838](https://redirect.github.com/biomejs/biome/issues/6838),
where the Biome File Watcher incorrectly watched and stored ignored
files, causing possible memory leaks when those files were dynamically
created (e.g. built files).
- [#​6879](https://redirect.github.com/biomejs/biome/pull/6879)
[`0059cd9`](https://redirect.github.com/biomejs/biome/commit/0059cd9b5e6ba33cabb5e153bd03e2041effb0cd)
Thanks [@​denbezrukov](https://redirect.github.com/denbezrukov)! -
Refactor: remove one level of indirection for CSS declarations with
semicolon
Previously, accessing a declaration from a list required an extra step:
```rust
item
.as_any_css_declaration_with_semicolon()
.as_css_declaration_with_semicolon()
```
Now, it can be done directly with:
```rust
item.as_css_declaration_with_semicolon()
```
- [#​6839](https://redirect.github.com/biomejs/biome/pull/6839)
[`4cd62d8`](https://redirect.github.com/biomejs/biome/commit/4cd62d8ae2e5cb24d6f308e05b38003486294548)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed a bug where the Biome Language Server didn't correctly ignore
specific files when `vcs.useIgnoreFile` is set to `true`.
- [#​6884](https://redirect.github.com/biomejs/biome/pull/6884)
[`5ff50f8`](https://redirect.github.com/biomejs/biome/commit/5ff50f8291ca6f8f59fccfc326c8f0bdc3127842)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! -
Improved the performance of `noImportCycles` by ~30%.
- [#​6903](https://redirect.github.com/biomejs/biome/pull/6903)
[`241dd9e`](https://redirect.github.com/biomejs/biome/commit/241dd9e487226fc58b4ceceaf3164e36d8e22d3b)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6829](https://redirect.github.com/biomejs/biome/issues/6829):
Fixed a false positive reported by `useImportExtensions` when importing
a `.js` file that had a matching `.d.ts` file in the same folder.
- [#​6846](https://redirect.github.com/biomejs/biome/pull/6846)
[`446112e`](https://redirect.github.com/biomejs/biome/commit/446112e79d695c50ca9cc9f2d25c91cf03115f50)
Thanks [@​darricheng](https://redirect.github.com/darricheng)! -
Fixed an issue where biome was using the wrong string quotes when the
classes string has quotes, resulting in invalid code after applying the
fix.
- [#​6823](https://redirect.github.com/biomejs/biome/pull/6823)
[`eebc48e`](https://redirect.github.com/biomejs/biome/commit/eebc48e0120958a39186f510278e1e5eacad3f1c)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! -
Improved
[#​6172](https://redirect.github.com/biomejs/biome/issues/6172):
Optimised the way function arguments are stored in Biome's type
inference. This led to about 10% performance improvement in
`RedisCommander.d.ts` and about 2% on `@next/font` type definitions.
- [#​6878](https://redirect.github.com/biomejs/biome/pull/6878)
[`3402976`](https://redirect.github.com/biomejs/biome/commit/340297602c1162928735d1c073d7a409c22e90bd)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed a bug where the Biome Language Server would apply an unsafe fix
when using the code action `quickfix.biome`.
Now Biome no longer applies an unsafe code fix when using the code
action `quickfix.biome`.
- [#​6794](https://redirect.github.com/biomejs/biome/pull/6794)
[`4d5fc0e`](https://redirect.github.com/biomejs/biome/commit/4d5fc0ef38f8c4ad820e297749efc83e983b5a91)
Thanks
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)!
- Fixed
[#​6719](https://redirect.github.com/biomejs/biome/issues/6719):
The `noInvalidUseBeforeDeclaration` rule covers additional use cases.
Examples:
```ts
type Bar = { [BAR]: true };
const BAR = "bar";
```
```ts
interface Bar {
child: { grandChild: { [BAR]: typeof BAR; enumFoo: EnumFoo } };
}
const BAR = "bar";
enum EnumFoo {
BAR = "bar",
}
```
- [#​6863](https://redirect.github.com/biomejs/biome/pull/6863)
[`531e97e`](https://redirect.github.com/biomejs/biome/commit/531e97e3f691e3ff34d2382fab414072ecb68e8b)
Thanks [@​dyc3](https://redirect.github.com/dyc3)! - Biome now
considers whether the linter is enabled when figuring out how the
project should be scanned. Resolves
[#​6815](https://redirect.github.com/biomejs/biome/issues/6815).
- [#​6832](https://redirect.github.com/biomejs/biome/pull/6832)
[`bdbc2b1`](https://redirect.github.com/biomejs/biome/commit/bdbc2b10ac21dcb35b41e93b17e712ba80f421ca)
Thanks [@​togami2864](https://redirect.github.com/togami2864)! -
Fixed
[#​6165](https://redirect.github.com/biomejs/biome/issues/6165):
Fixed false negative in
[`noUnusedPrivateClassMembers`](https://biomejs.dev/linter/rules/no-unused-private-class-members/)
rule when checking member usage in classes
- [#​6839](https://redirect.github.com/biomejs/biome/pull/6839)
[`4cd62d8`](https://redirect.github.com/biomejs/biome/commit/4cd62d8ae2e5cb24d6f308e05b38003486294548)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed a bug where the root ignore file wasn't correctly loaded during
the scanning phase, causing false positives and incorrect expectations
among users.
Now, when using `vcs.useIgnoreFile`, the **the globs specified in the
ignore file from the project root** will have the same semantics as the
`files.includes` setting of the root configuration.
Refer to the [relative web
page](https://biomejs.dev/internals/architecture/#configuring-the-scanner)
to understand how they work.
- [#​6898](https://redirect.github.com/biomejs/biome/pull/6898)
[`5beb024`](https://redirect.github.com/biomejs/biome/commit/5beb024d8e9af8733bc115ba4b07d20036fe336e)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6891](https://redirect.github.com/biomejs/biome/issues/6891):
Improved type inference for array indices.
**Example:**
```ts
const numbers: number[];
numbers[42]; // This now infers to `number | undefined`.
```
- [#​6809](https://redirect.github.com/biomejs/biome/pull/6809)
[`8192451`](https://redirect.github.com/biomejs/biome/commit/819245188e587d0a5ede53aa07899a2cb9fcce4f)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6796](https://redirect.github.com/biomejs/biome/issues/6796):
Fixed a false positive that happened in `noFloatingPromises` when
calling functions that were declared as part of `for ... of` syntax
inside `async` functions.
Instead, the variables declared inside `for ... of` loops are now
correctly
inferred if the expression being iterated evaluates to an `Array`
(support for other iterables will follow later).
**Invalid example**
```tsx
const txStatements: Array<(tx) => Promise<any>> = [];
db.transaction((tx: any) => {
for (const stmt of txStatements) {
// We correctly flag this resolves to a `Promise`:
stmt(tx);
}
});
```
**Valid example**
```tsx
async function valid(db) {
const txStatements: Array<(tx: any) => void> = [(tx) =>
tx.insert().run()];
db.transaction((tx: any) => {
for (const stmt of txStatements) {
// We don't flag a false positive here anymore:
stmt(tx);
}
});
}
```
- [#​6757](https://redirect.github.com/biomejs/biome/pull/6757)
[`13a0818`](https://redirect.github.com/biomejs/biome/commit/13a0818be8cc08efd303829252cbc3e64bcbca3a)
Thanks [@​mdevils](https://redirect.github.com/mdevils)! - Added
the rule
[`noVueReservedProps`](https://biomejs.dev/linter/rules/no-vue-reserved-props/),
resolves
[#​6309](https://redirect.github.com/biomejs/biome/issues/6309).
It prevents the use of reserved Vue prop names such as `key` and `ref`
which can cause conflicts and unexpected behavior in Vue components.
##### Invalid example
```js
import { defineComponent } from "vue";
export default defineComponent({
props: ["ref", "key", "foo"],
});
```
```vue
<script setup>
defineProps({
ref: String,
key: String,
foo: String,
});
</script>
```
##### Valid examples
```js
import { defineComponent } from "vue";
export default defineComponent({
props: ["foo"],
});
```
```vue
<script setup>
defineProps({ foo: String });
</script>
```
- [#​6840](https://redirect.github.com/biomejs/biome/pull/6840)
[`1a57b51`](https://redirect.github.com/biomejs/biome/commit/1a57b51097c7bf4faeb0dcc5330d49e17f86789b)
Thanks [@​denbezrukov](https://redirect.github.com/denbezrukov)! -
Allow multiple identifiers in ::part() pseudo-element selector.
```css
::part(first second) {
}
```
- [#​6845](https://redirect.github.com/biomejs/biome/pull/6845)
[`4fd44ec`](https://redirect.github.com/biomejs/biome/commit/4fd44ec17a3ac6a5486ac94f01e85e62310b8061)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6510](https://redirect.github.com/biomejs/biome/issues/6510):
The scanner no longer shows diagnostics on inaccessible files unless
`--verbose` is used.
- [#​6844](https://redirect.github.com/biomejs/biome/pull/6844)
[`b7e2d4d`](https://redirect.github.com/biomejs/biome/commit/b7e2d4d3a8b2654278596eaecdccc30405457fc8)
Thanks [@​sterliakov](https://redirect.github.com/sterliakov)! -
Fixed
[#​6837](https://redirect.github.com/biomejs/biome/issues/6837):
Fixed regression with multiple consecutive line suppression comments
using instances (like `// biome-ignore
lint/correctness/useExhaustiveDependencies(depName): reason`).
- [#​6818](https://redirect.github.com/biomejs/biome/pull/6818)
[`5f3f5a6`](https://redirect.github.com/biomejs/biome/commit/5f3f5a6e8c12b56dc36bcfb4f8d5077eb33ccf08)
Thanks [@​siketyan](https://redirect.github.com/siketyan)! - Fixed
an issue where `textDocument/codeAction` in the LSP could respond with
outdated text edits after the workspace watcher observed outdated
changes to the file.
- [#​6804](https://redirect.github.com/biomejs/biome/pull/6804)
[`3e6ab16`](https://redirect.github.com/biomejs/biome/commit/3e6ab1663ab15f9f00ae069ee790e5fd90327082)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! -
`noFloatingPromises` will no longer suggest to add `await` keyword
inside synchronous callbacks nested inside `async` functions.
- [#​6901](https://redirect.github.com/biomejs/biome/pull/6901)
[`c9e969a`](https://redirect.github.com/biomejs/biome/commit/c9e969a84158b29d175cd04ea8b921c737b7ed8f)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6777](https://redirect.github.com/biomejs/biome/issues/6777):
Fixed type inference handling of `this` to avoid infinite recursion.
Thanks to [@​sterliakov](https://redirect.github.com/sterliakov)
for the thorough investigation!
- [#​6855](https://redirect.github.com/biomejs/biome/pull/6855)
[`d1581c7`](https://redirect.github.com/biomejs/biome/commit/d1581c7c874b2917132a864d1c65df041ad9181b)
Thanks
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)!
- Fixed
[#​6775](https://redirect.github.com/biomejs/biome/issues/6775):
`useReadonlyClassProperties` now also captures mutations inside function
arguments.
Example:
```ts
class Counter {
private counter: number;
count() {
console.log(this.counter++);
const counterString = `${this.counter++}`;
}
}
```
- [#​6839](https://redirect.github.com/biomejs/biome/pull/6839)
[`4cd62d8`](https://redirect.github.com/biomejs/biome/commit/4cd62d8ae2e5cb24d6f308e05b38003486294548)
Thanks [@​ematipico](https://redirect.github.com/ematipico)! -
Fixed a bug where Biome didn't throw any error when `vcs.useIgnoreFile`
is set to `true`, and there wasn't any ignore file read. Now Biome
correctly throws an error if no ignore files are found.
- [#​6911](https://redirect.github.com/biomejs/biome/pull/6911)
[`6d68074`](https://redirect.github.com/biomejs/biome/commit/6d68074bf2a2ca4bc514398a180524394690fafe)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6838](https://redirect.github.com/biomejs/biome/issues/6838):
Reduce resource consumption in the Biome Language Server by using
non-recursive filesystem watchers instead of recursive ones.
Watchers are responsible for notifying Biome of changes to files in the
filesystem. We used to set up a single recursive watcher, but that meant
that Biome would receive filesystem notifications for *all* files in
your project, even for ignored folders such as `build/` or `dist/`
folders.
With this patch, we set up non-recursive watchers only for the folders
that are relevant to a project.
Related to this, we also solved an issue where incoming notifications
were incorrectly filtered, causing ignored files to be processed and
stored in our module graph anyway.
#### What's Changed
- chore: check milestone before releasing by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6791](https://redirect.github.com/biomejs/biome/pull/6791)
- chore: add tracing span for `open_file_internal()` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6803](https://redirect.github.com/biomejs/biome/pull/6803)
- fix(core): correctly identify sync callbacks inside async functions by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6804](https://redirect.github.com/biomejs/biome/pull/6804)
- fix(core): do not update the opened document when change observed by
the watcher by [@​siketyan](https://redirect.github.com/siketyan)
in
[https://github.com/biomejs/biome/pull/6818](https://redirect.github.com/biomejs/biome/pull/6818)
- feat(html/parser): text expressions by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6802](https://redirect.github.com/biomejs/biome/pull/6802)
- feat(lint): implement `noVueReservedProps` rule by
[@​mdevils](https://redirect.github.com/mdevils) in
[https://github.com/biomejs/biome/pull/6757](https://redirect.github.com/biomejs/biome/pull/6757)
- ci: add a job for linting markdown files by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6825](https://redirect.github.com/biomejs/biome/pull/6825)
- perf: faster function parameters in inference by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6823](https://redirect.github.com/biomejs/biome/pull/6823)
- fix(core): infer for-of and for-in loop variables by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6809](https://redirect.github.com/biomejs/biome/pull/6809)
- chore: fix typo by
[@​nhedger](https://redirect.github.com/nhedger) in
[https://github.com/biomejs/biome/pull/6834](https://redirect.github.com/biomejs/biome/pull/6834)
- fix(noUnusedPrivateClassMembers): improve member usage checks in the
class by [@​togami2864](https://redirect.github.com/togami2864) in
[https://github.com/biomejs/biome/pull/6832](https://redirect.github.com/biomejs/biome/pull/6832)
- fix(core): silence diagnostics in scanner by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6845](https://redirect.github.com/biomejs/biome/pull/6845)
- feat: add global vscode and zed settings file to well known files by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6798](https://redirect.github.com/biomejs/biome/pull/6798)
- fix(css\_parser): support a list of identifiers in ::part()
pseudo-element selector by
[@​denbezrukov](https://redirect.github.com/denbezrukov) in
[https://github.com/biomejs/biome/pull/6840](https://redirect.github.com/biomejs/biome/pull/6840)
- fix(biome\_js\_analyze): fixed noInvalidUseBeforeDeclaration false
positives by
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)
in
[https://github.com/biomejs/biome/pull/6794](https://redirect.github.com/biomejs/biome/pull/6794)
- fix: classes with single quotes in functions should use double quotes
by [@​darricheng](https://redirect.github.com/darricheng) in
[https://github.com/biomejs/biome/pull/6846](https://redirect.github.com/biomejs/biome/pull/6846)
- chore: fix `just new*` commands by
[@​mdevils](https://redirect.github.com/mdevils) in
[https://github.com/biomejs/biome/pull/6853](https://redirect.github.com/biomejs/biome/pull/6853)
- chore: fix `noVueReservedProps` changeset by
[@​mdevils](https://redirect.github.com/mdevils) in
[https://github.com/biomejs/biome/pull/6858](https://redirect.github.com/biomejs/biome/pull/6858)
- chore: remove platinum sponsor by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6854](https://redirect.github.com/biomejs/biome/pull/6854)
- chore(deps): update github-actions by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6869](https://redirect.github.com/biomejs/biome/pull/6869)9
- chore(deps): update dependency eslint to v9.31.0 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6868](https://redirect.github.com/biomejs/biome/pull/6868)8
- chore(deps): update dependency
[@​types/node](https://redirect.github.com/types/node) to v22.16.3
by [@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6866](https://redirect.github.com/biomejs/biome/pull/6866)6
- chore(deps): update dependency
[@​types/node](https://redirect.github.com/types/node) to v22.16.3
by [@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6867](https://redirect.github.com/biomejs/biome/pull/6867)7
- chore(deps): update typescript-eslint monorepo to v8.36.0 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6873](https://redirect.github.com/biomejs/biome/pull/6873)3
- feat(cli): consider configuration when selecting ScanKind by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6863](https://redirect.github.com/biomejs/biome/pull/6863)
- docs(noImportCycles): add note about computation cost by
[@​dyc3](https://redirect.github.com/dyc3) in
[https://github.com/biomejs/biome/pull/6864](https://redirect.github.com/biomejs/biome/pull/6864)
- fix(css\_parser): handle multiple semicolons correctly in blocks
([#​6485](https://redirect.github.com/biomejs/biome/issues/6485))
by [@​denbezrukov](https://redirect.github.com/denbezrukov) in
[https://github.com/biomejs/biome/pull/6865](https://redirect.github.com/biomejs/biome/pull/6865)
- fix(deps): update dependency prettier to v3.6.2 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6874](https://redirect.github.com/biomejs/biome/pull/6874)4
- chore(deps): update rust crate tokio to 1.46.1 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6871](https://redirect.github.com/biomejs/biome/pull/6871)1
- chore(deps): update rust crate criterion to v3 by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6876](https://redirect.github.com/biomejs/biome/pull/6876)6
- fix(deps): update rust crates by
[@​renovate](https://redirect.github.com/renovate)\[bot]
in[https://github.com/biomejs/biome/pull/6875](https://redirect.github.com/biomejs/biome/pull/6875)5
- fix(lsp): skip unsafe fixes with quick fixes by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6878](https://redirect.github.com/biomejs/biome/pull/6878)
- perf: optimise `noImportCycles` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6884](https://redirect.github.com/biomejs/biome/pull/6884)
- refactor(css\_parser): flatten AnyCssDeclarationWithSemicolon
([#​6912](https://redirect.github.com/biomejs/biome/issues/6912))
by [@​denbezrukov](https://redirect.github.com/denbezrukov) in
[https://github.com/biomejs/biome/pull/6879](https://redirect.github.com/biomejs/biome/pull/6879)
- feat(biome\_js\_analyze): added support for call expressions arguments
by
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)
in
[https://github.com/biomejs/biome/pull/6855](https://redirect.github.com/biomejs/biome/pull/6855)
- fix(core): scanner ignores files inside VCS by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6839](https://redirect.github.com/biomejs/biome/pull/6839)
- fix(biome\_analyze): restore support for multiple consecutive
suppression comments with rule instances. by
[@​sterliakov](https://redirect.github.com/sterliakov) in
[https://github.com/biomejs/biome/pull/6844](https://redirect.github.com/biomejs/biome/pull/6844)
- refactor: make Watcher aware of `ScanKind` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6842](https://redirect.github.com/biomejs/biome/pull/6842)
- fix(core): infer array indices by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6898](https://redirect.github.com/biomejs/biome/pull/6898)
- fix(core): fix type inference of `this` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6901](https://redirect.github.com/biomejs/biome/pull/6901)
- fix(linter): fix false positive with `.d.ts` files in
`useImportExtensions` by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6903](https://redirect.github.com/biomejs/biome/pull/6903)
- ci: release by
[@​github-actions](https://redirect.github.com/github-actions)\[bot]
in[https://github.com/biomejs/biome/pull/6807](https://redirect.github.com/biomejs/biome/pull/6807)7
- Revert "ci: release" by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6908](https://redirect.github.com/biomejs/biome/pull/6908)
- fix(cli): apply `--assist-enabled` by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6912](https://redirect.github.com/biomejs/biome/pull/6912)
- fix(core): use non-recursive watchers by
[@​arendjr](https://redirect.github.com/arendjr) in
[https://github.com/biomejs/biome/pull/6911](https://redirect.github.com/biomejs/biome/pull/6911)
- feat(yaml\_parser): parse block sequence by
[@​vohoanglong0107](https://redirect.github.com/vohoanglong0107)
in
[https://github.com/biomejs/biome/pull/6727](https://redirect.github.com/biomejs/biome/pull/6727)
- feat(linter): add `excludedComponents` option to `useUniqueElementIds`
by [@​sterliakov](https://redirect.github.com/sterliakov) in
[https://github.com/biomejs/biome/pull/6723](https://redirect.github.com/biomejs/biome/pull/6723)
- ci: release by
[@​github-actions](https://redirect.github.com/github-actions)\[bot]
in[https://github.com/biomejs/biome/pull/6909](https://redirect.github.com/biomejs/biome/pull/6909)9
#### New Contributors
- [@​darricheng](https://redirect.github.com/darricheng) made
their first contribution in
[https://github.com/biomejs/biome/pull/6846](https://redirect.github.com/biomejs/biome/pull/6846)
**Full Changelog**:
https://github.com/biomejs/biome/compare/[@​biomejs/js-api](https://redirect.github.com/biomejs/js-api)@​2.0.3...[@​biomejs/biome](https://redirect.github.com/biomejs/biome)@​2.1.2
###
[`v2.1.1`](https://redirect.github.com/biomejs/biome/releases/tag/%40biomejs/biome%402.1.1):
Biome CLI v2.1.1
#### 2.1.1
##### Patch Changes
- [#​6781](https://redirect.github.com/biomejs/biome/pull/6781)
[`9bbd34f`](https://redirect.github.com/biomejs/biome/commit/9bbd34f8d4be3dd4ba4c63746a5b2915e578e339)
Thanks [@​siketyan](https://redirect.github.com/siketyan)! - Fixed
the `FileFeaturesResult` interface in the WASM API was defined as a
mapped object but the actual value was a `Map` object.
- [#​6761](https://redirect.github.com/biomejs/biome/pull/6761)
[`cf3c2ce`](https://redirect.github.com/biomejs/biome/commit/cf3c2ce3ac28a36eee948ad689794783b0ba23ef)
Thanks [@​dyc3](https://redirect.github.com/dyc3)! - Fixed
[#​6759](https://redirect.github.com/biomejs/biome/issues/6759), a
false positive for `noFocusedTests` that was triggered by calling any
function with the name `fit` on any object.
The following code will now pass the `noFocusedTests` rule:
```js
import foo from "foo";
foo.fit();
```
#### What's Changed
- ci: correct restore path of the artifact by
[@​siketyan](https://redirect.github.com/siketyan) in
[https://github.com/biomejs/biome/pull/6780](https://redirect.github.com/biomejs/biome/pull/6780)
- fix(wasm): serialize map as a plain object by
[@​siketyan](https://redirect.github.com/siketyan) in
[https://github.com/biomejs/biome/pull/6781](https://redirect.github.com/biomejs/biome/pull/6781)
- ci: release by
[@​github-actions](https://redirect.github.com/github-actions) in
[https://github.com/biomejs/biome/pull/6779](https://redirect.github.com/biomejs/biome/pull/6779)
- docs: update contribution guide and pull request template by
[@​ematipico](https://redirect.github.com/ematipico) in
[https://github.com/biomejs/biome/pull/6664](https://redirect.github.com/biomejs/biome/pull/6664)
**Full Changelog**:
https://github.com/biomejs/biome/compare/[@​biomejs/js-api](https://redirect.github.com/biomejs/js-api)@​2.0.1...[@​biomejs/biome](https://redirect.github.com/biomejs/biome)@​2.1.1
###
[`v2.1.0`](https://redirect.github.com/biomejs/biome/releases/tag/%40biomejs/biome%402.1.0):
Biome CLI v2.1.0
#### 2.1.0
##### Minor Changes
- [#​6512](https://redirect.github.com/biomejs/biome/pull/6512)
[`0c0bf82`](https://redirect.github.com/biomejs/biome/commit/0c0bf82c92ee4e853172f44e38af57afde6de2ce)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - The
rule
[`noFloatingPromises`](https://biomejs.dev/linter/rules/no-misused-promises/)
can now detect floating arrays of `Promise`s.
**Invalid examples**
```ts
// This gets flagged because the Promises are not handled.
[1, 2, 3].map(async (x) => x + 1);
```
**Valid examples**
```ts
await Promise.all([1, 2, 3].map(async (x) => x + 1));
```
- [#​6637](https://redirect.github.com/biomejs/biome/pull/6637)
[`6918085`](https://redirect.github.com/biomejs/biome/commit/6918085e14b8e34bfd0adc472acce22c31484ab3)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Type
inference is now able to handle the sequence operator (`,`), as well as
post- and pre-update operators: `++`.
**Example**
```ts
let x = 5;
// We now infer that `x++` resolves to a number, while the expression as
a whole
// becomes a Promise:
x++, new Promise((resolve) => resolve("comma"));
```
- [#​6752](https://redirect.github.com/biomejs/biome/pull/6752)
[`c9eaca4`](https://redirect.github.com/biomejs/biome/commit/c9eaca4b944acfd18b700c65c904806b11c318d5)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6646](https://redirect.github.com/biomejs/biome/issues/6646):
`.gitignore` files are now picked up even when running Biome from a
nested directory, or when the ignore file itself is ignored through
`files.includes`.
- [#​6746](https://redirect.github.com/biomejs/biome/pull/6746)
[`90aeead`](https://redirect.github.com/biomejs/biome/commit/90aeeadf80700aee9f29121511d0c4c9019a49d6)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - `biome
migrate` no longer enables style rules that were recommended in v1,
because that would be undesirable for users upgrading from 2.0.
Users who are upgrading from Biome 1.x are therefore advised to first
upgrade to Biome 2.0, and run the migration, before continuing to Biome
2.1 or later.
- [#​6583](https://redirect.github.com/biomejs/biome/pull/6583)
[`d415a3f`](https://redirect.github.com/biomejs/biome/commit/d415a3f6f204cc7b109dc08f6117fe97ef07b216)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Added
the nursery rule
[`noMisusedPromises`](https://biomejs.dev/linter/rules/no-misused-promises/).
It signals `Promise`s in places where conditionals or iterables are
expected.
**Invalid examples**
```ts
const promise = Promise.resolve("value");
// Using a `Promise` as conditional is always truthy:
if (promise) {
/* ... */
}
// Spreading a `Promise` has no effect:
console.log({ foo: 42, ...promise });
// This does not `await` the `Promise`s from the callbacks,
// so it does not behave as you may expect:
[1, 2, 3].forEach(async (value) => {
await fetch(`/${value}`);
});
```
**Valid examples**
```ts
const promise = Promise.resolve("value");
if (await promise) {
/* ... */
}
console.log({ foo: 42, ...(await promise) });
```
- [#​6405](https://redirect.github.com/biomejs/biome/pull/6405)
[`cd4a9bb`](https://redirect.github.com/biomejs/biome/commit/cd4a9bbdcbc176fa2294fd5a2a2565a13b12a51d)
Thanks
[@​vladimir-ivanov](https://redirect.github.com/vladimir-ivanov)!
- Added the `ignoreRestSiblings` option to the
`noUnusedFunctionParameters` rule.
This option is used to ignore unused function parameters that are
siblings of the rest parameter.
The default is `false`, which means that unused function parameters that
are siblings of the rest parameter will be reported.
**Example**
```json
{
"rules": {
"noUnusedFunctionParameters": ["error", { "ignoreRestSiblings": true }]
}
}
```
- [#​6614](https://redirect.github.com/biomejs/biome/pull/6614)
[`0840021`](https://redirect.github.com/biomejs/biome/commit/0840021860fcc5e9055f781dce84e80353f9f5ce)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - We have
implemented a more targeted version of the scanner, which ensures that
if you provide file paths to handle on the CLI, the scanner will exclude
directories that are not relevant to those paths.
Note that for many commands, such as `biome check` and `biome format`,
the file paths to handle are implicitly set to the current working
directory if you do not provide any path explicitly. The targeted
scanner also works with such implicit paths, which means that if you run
Biome from a subfolder, other folders that are part of the project are
automatically exempted.
Use cases where you invoke Biome from the root of the project without
providing a path, as well as those where project rules are enabled, are
not expected to see performance benefits from this.
Implemented
[#​6234](https://redirect.github.com/biomejs/biome/issues/6234),
and fixed
[#​6483](https://redirect.github.com/biomejs/biome/issues/6483)
and
[#​6563](https://redirect.github.com/biomejs/biome/issues/6563).
- [#​6488](https://redirect.github.com/biomejs/biome/pull/6488)
[`c5ee385`](https://redirect.github.com/biomejs/biome/commit/c5ee38569fc0b91ea9411da25560d3a1076870c6)
Thanks [@​ianzone](https://redirect.github.com/ianzone)! -
`nx.json` and `project.json` have been added to the list of well-known
files.
- [#​6720](https://redirect.github.com/biomejs/biome/pull/6720)
[`52e36ae`](https://redirect.github.com/biomejs/biome/commit/52e36ae827d2c9f02520298d6518a00b22db38b8)
Thanks [@​minht11](https://redirect.github.com/minht11)! - Added
`# @​biomejs/biome symbol to
[organizeImports](https://biomejs.dev/assist/actions/organize-imports)
`:ALIAS:\` group.
`import { action } from '$lib'` will be treated as alias import.
##### Patch Changes
- [#​6712](https://redirect.github.com/biomejs/biome/pull/6712)
[`2649ac6`](https://redirect.github.com/biomejs/biome/commit/2649ac625de963bf7411368cdd06142bda362322)
Thanks [@​sterliakov](https://redirect.github.com/sterliakov)! -
Fixed
[#​6595](https://redirect.github.com/biomejs/biome/issues/6595):
Biome now supports `// biome-ignore-all` file-level suppressions in
files that start with a shebang (`#!`).
- [#​6758](https://redirect.github.com/biomejs/biome/pull/6758)
[`28dc49e`](https://redirect.github.com/biomejs/biome/commit/28dc49eacb9da1073d56070eb70b10ed636a1799)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Fixed
[#​6573](https://redirect.github.com/biomejs/biome/issues/6573):
Grit plugins can now match bare imports.
**Example**
The following snippet:
```grit
`import $source`
```
will now match:
```ts
import "main.css";
```
- [#​6550](https://redirect.github.com/biomejs/biome/pull/6550)
[`b424f46`](https://redirect.github.com/biomejs/biome/commit/b424f4682cdcba5bf4cd6eb4b34486b631ddfbdc)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Type
inference is now able to handle logical expressions: `&&`, `||`, and
`??`.
**Examples**
```ts
// We can now infer that because `true` is truthy, the entire expression
// evaluates to a `Promise`.
true && Promise.reject("logical operator bypass");
// And we know that this doesn't:
false && Promise.reject("logical operator bypass");
// Truthiness, falsiness, and non-nullishness can all be determined on
more
// complex expressions as well. So the following also works:
type Nullish = null | undefined;
type Params = {
booleanOption: boolean | Nullish;
falsyOption: false | Nullish;
};
function foo({ booleanOption, falsyOption }: Params) {
// This may be a Promise:
booleanOption ?? Promise.reject("logical operator bypass");
// But this never is:
falsyOption && Promise.reject("logical operator bypass");
}
```
- [#​6413](https://redirect.github.com/biomejs/biome/pull/6413)
[`4aa0e50`](https://redirect.github.com/biomejs/biome/commit/4aa0e50a91f457a059b225f140d9fa44ea08a8fb)
Thanks [@​wojtekmaj](https://redirect.github.com/wojtekmaj)! -
Improved error message in
[`useDateNow`](https://biomejs.dev/linter/rules/use-date-now/) rule.
- [#​6673](https://redirect.github.com/biomejs/biome/pull/6673)
[`341e062`](https://redirect.github.com/biomejs/biome/commit/341e062bc28f32adc2ee44c26ab4fb0574750319)
Thanks [@​dyc3](https://redirect.github.com/dyc3)! - Fixed a case
where the HTML formatter would mangle embedded language tags if
`whitespaceSensitivity` was set to `strict`
- [#​6642](https://redirect.github.com/biomejs/biome/pull/6642)
[`a991229`](https://redirect.github.com/biomejs/biome/commit/a99122902eb01907f03565d2c7e56186d01764d3)
Thanks [@​unvalley](https://redirect.github.com/unvalley)! - Fixed
[#​4494](https://redirect.github.com/biomejs/biome/issues/4494):
The `noSecrets` rule now correctly uses the `entropyThreshold` option to
detect secret like strings.
- [#​6520](https://redirect.github.com/biomejs/biome/pull/6520)
[`0c43545`](https://redirect.github.com/biomejs/biome/commit/0c43545934ba50ca0dbb0581f274e0e41a7e26e7)
Thanks [@​arendjr](https://redirect.github.com/arendjr)! - Type
inference is now able to handle ternary
</details>
---
### Configuration
📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM, only on
Monday ( * 0-3 * * 1 ) (UTC), Automerge - At any time (no schedule
defined).
🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/alecthomas/chroma).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0MS4yMy4yIiwidXBkYXRlZEluVmVyIjoiNDEuNDYuMyIsInRhcmdldEJyYW5jaCI6Im1hc3RlciIsImxhYmVscyI6W119-->
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>1 parent 4a1dcb2 commit 14227eeCopy full SHA for 14227ee
File tree
Expand file treeCollapse file tree
2 files changed
+1
-1
lines changedFilter options
- bin
Expand file treeCollapse file tree
2 files changed
+1
-1
lines changedbin/.biome-1.9.4.pkg renamed to bin/.biome-2.1.3.pkg
Copy file name to clipboardFile renamed without changes.
bin/biome
Copy file name to clipboard+1-1Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 |
| - | |
| 1 | + |
0 commit comments