Vai al contenuto
verdict:

Biome 2.2.6

digest

note: la sintesi e le note di rilascio sono in inglese

note: nessuna sintesi per questa release digest

Le release digest sono elencate senza una sintesi. Le note di rilascio originali di questa versione sono qui sotto.

release-notesgithub.com/biomejs/biome · 168 righe
  1. ## 2.2.6
  2. ### Patch Changes
  3. - [#7071](https://github.com/biomejs/biome/pull/7071) [`a8e7301`](https://github.com/biomejs/biome/commit/a8e73018a8c9e34a182624a91389e19d1fa7817f) Thanks [@ptkagori](https://github.com/ptkagori)! - Added the [`useQwikMethodUsage`](https://biomejs.dev/linter/rules/use-qwik-method-usage) lint rule for the Qwik domain.
  4. This rule validates Qwik hook usage. Identifiers matching `useXxx` must be called only within serialisable reactive contexts (for example, inside `component$`, route loaders/actions, or within other Qwik hooks), preventing common Qwik antipatterns.
  5. **Invalid:**
  6. ```js
  7. // Top-level hook call is invalid.
  8. const state = useStore({ count: 0 });
  9. function helper() {
  10. // Calling a hook in a non-reactive function is invalid.
  11. const loc = useLocation();
  12. }
  13. ```
  14. **Valid:**
  15. ```js
  16. component$(() => {
  17. const state = useStore({ count: 0 }); // OK inside component$.
  18. return <div>{state.count}</div>;
  19. });
  20. const handler = $(() => {
  21. const loc = useLocation(); // OK inside a $-wrapped closure.
  22. console.log(loc.params);
  23. });
  24. ```
  25. - [#7685](https://github.com/biomejs/biome/pull/7685) [`52071f5`](https://github.com/biomejs/biome/commit/52071f54bc1a3c5d1d2ee6039c5feead836638ed) Thanks [@denbezrukov](https://github.com/denbezrukov)! - Fixed [#6981](https://github.com/biomejs/biome/issues/6981): The [NoUnknownPseudoClass](https://biomejs.dev/linter/rules/no-unknown-pseudo-class/) rule no longer reports local pseudo-classes when CSS Modules are used.
  26. - [#7640](https://github.com/biomejs/biome/pull/7640) [`899f7b2`](https://github.com/biomejs/biome/commit/899f7b28ec9cc457d02565d69212e7c29b5b5aff) Thanks [@arendjr](https://github.com/arendjr)! - Fixed [#7638](https://github.com/biomejs/biome/issues/7638): [`useImportExtensions`](https://biomejs.dev/linter/rules/use-import-extensions/) no longer emits diagnostics on valid import paths that end with a query or hash.
  27. #### Example
  28. ```js
  29. // This no longer warns if `index.css` exists:
  30. import style from "../theme/index.css?inline";
  31. ```
  32. - [#7071](https://github.com/biomejs/biome/pull/7071) [`a8e7301`](https://github.com/biomejs/biome/commit/a8e73018a8c9e34a182624a91389e19d1fa7817f) Thanks [@ptkagori](https://github.com/ptkagori)! - Added the [`useQwikValidLexicalScope`](https://biomejs.dev/linter/rules/use-qwik-valid-lexical-scope) rule to the Qwik domain.
  33. This rule helps you avoid common bugs in Qwik components by checking that your variables and functions are declared in the correct place.
  34. **Invalid:**
  35. ```js
  36. // Invalid: state defined outside the component's lexical scope.
  37. let state = useStore({ count: 0 });
  38. const Component = component$(() => {
  39. return (
  40. <button onClick$={() => state.count++}>Invalid: {state.count}</button>
  41. );
  42. });
  43. ```
  44. **Valid:**
  45. ```js
  46. // Valid: state initialised within the component's lexical scope and captured by the event.
  47. const Component = component$(() => {
  48. const state = useStore({ count: 0 });
  49. return <button onClick$={() => state.count++}>Valid: {state.count}</button>;
  50. });
  51. ```
  52. - [#7620](https://github.com/biomejs/biome/pull/7620) [`5beb1ee`](https://github.com/biomejs/biome/commit/5beb1eefe134f4dc713cfb28bfa1cbae38319975) Thanks [@Netail](https://github.com/Netail)! - Added the rule [`useDeprecatedDate`](https://biomejs.dev/linter/rules/use-deprecated-date/), which makes a deprecation date required for the graphql `@deprecated` directive.
  53. ##### Invalid
  54. ```graphql
  55. query {
  56. member @deprecated(reason: "Use `members` instead") {
  57. id
  58. }
  59. }
  60. ```
  61. ##### Valid
  62. ```graphql
  63. query {
  64. member
  65. @deprecated(reason: "Use `members` instead", deletionDate: "2099-12-25") {
  66. id
  67. }
  68. }
  69. ```
  70. - [#7709](https://github.com/biomejs/biome/pull/7709) [`d6da4d5`](https://github.com/biomejs/biome/commit/d6da4d5a272d61420997e26aef80f53298515665) Thanks [@siketyan](https://github.com/siketyan)! - Fixed [#7704](https://github.com/biomejs/biome/issues/7704): The [`useExhaustiveDependencies`](https://biomejs.dev/linter/rules/use-exhaustive-dependencies/) rule now correctly adds an object dependency when its method is called within the closure.
  71. For example:
  72. ```js
  73. function Component(props) {
  74. useEffect(() => {
  75. props.foo();
  76. }, []);
  77. }
  78. ```
  79. will now be fixed to:
  80. ```js
  81. function Component(props) {
  82. useEffect(() => {
  83. props.foo();
  84. }, [props]);
  85. }
  86. ```
  87. - [#7624](https://github.com/biomejs/biome/pull/7624) [`309ae41`](https://github.com/biomejs/biome/commit/309ae41c1a29e50d71300d3e63f6c64ee6ecb968) Thanks [@lucasweng](https://github.com/lucasweng)! - Fixed [#7595](https://github.com/biomejs/biome/issues/7595): [`noUselessEscapeInString`](https://biomejs.dev/linter/rules/no-useless-escape-in-string/) no longer reports `$\{` escape in template literals.
  88. - [#7665](https://github.com/biomejs/biome/pull/7665) [`29e4229`](https://github.com/biomejs/biome/commit/29e422939f25595dca4f19735a27258d97545288) Thanks [@ryan-m-walker](https://github.com/ryan-m-walker)! - Fixed [#7619](https://github.com/biomejs/biome/issues/7619): Added support for parsing the CSS `:state()` pseudo-class.
  89. ```css
  90. custom-selector:state(checked) {
  91. }
  92. ```
  93. - [#7608](https://github.com/biomejs/biome/pull/7608) [`41df59b`](https://github.com/biomejs/biome/commit/41df59bfc6d49190b9c35fa262def3ecfcc6abd2) Thanks [@ritoban23](https://github.com/ritoban23)! - Fixed [#7604](https://github.com/biomejs/biome/issues/7604): the `useMaxParams` rule now highlights parameter lists instead of entire function bodies. This provides more precise error highlighting. Previously, the entire function was highlighted; now only the parameter list is highlighted, such as `(a, b, c, d, e, f, g, h)`.
  94. - [#7643](https://github.com/biomejs/biome/pull/7643) [`459a6ac`](https://github.com/biomejs/biome/commit/459a6aca67290e8b974802bd693738f79883d67e) Thanks [@daivinhtran](https://github.com/daivinhtran)! - Fixed [#7580](https://github.com/biomejs/biome/issues/7580): Include plugin in summary report
  95. ## What's Changed
  96. * chore: add .zed to gitignore by @daivinhtran in https://github.com/biomejs/biome/pull/7634
  97. * fix(lint/noUselessEscapeInString): avoid false positive for $\{ escape in template literals by @lucasweng in https://github.com/biomejs/biome/pull/7624
  98. * fix(lint): only highlight function names in useMaxParams rule by @ritoban23 in https://github.com/biomejs/biome/pull/7608
  99. * docs: add Polish translation of Biome README by @SzymCode in https://github.com/biomejs/biome/pull/7630
  100. * fix(linter): `useImportExtensions` handles queries and hashes by @arendjr in https://github.com/biomejs/biome/pull/7640
  101. * ci: breakdown benchmarks by @ematipico in https://github.com/biomejs/biome/pull/7641
  102. * chore: upgrade to rust 1.90.0 by @ematipico in https://github.com/biomejs/biome/pull/7642
  103. * fix(css_parser): add support for parsing :state() (#7619) by @ryan-m-walker in https://github.com/biomejs/biome/pull/7665
  104. * fix(cli): include plugin rule in summary report by @daivinhtran in https://github.com/biomejs/biome/pull/7643
  105. * feat(qwik): add useQwikMethodUsage & useQwikValidLexicalScope by @ptkagori in https://github.com/biomejs/biome/pull/7071
  106. * fix: replace domains polyfill.io to Cloudflare by @You-saku in https://github.com/biomejs/biome/pull/7678
  107. * feat(biome_graphql_analyze): implement `useDeprecatedDate` by @Netail in https://github.com/biomejs/biome/pull/7620
  108. * chore(deps): update dependency @types/node to v22.18.8 by @renovate[bot] in https://github.com/biomejs/biome/pull/7686
  109. * chore(deps): update github-actions by @renovate[bot] in https://github.com/biomejs/biome/pull/7687
  110. * chore(deps): update rust crate regex to 1.11.3 by @renovate[bot] in https://github.com/biomejs/biome/pull/7689
  111. * chore(deps): update rust crate quote to 1.0.41 by @renovate[bot] in https://github.com/biomejs/biome/pull/7688
  112. * chore(deps): update dependency eslint to v9.37.0 by @renovate[bot] in https://github.com/biomejs/biome/pull/7691
  113. * chore(deps): update rust crate serde to 1.0.228 by @renovate[bot] in https://github.com/biomejs/biome/pull/7690
  114. * fix(css_analyze): handle CSS Modules pseudo-class 'local' in NoUnknownPseudoClass rule (#6981) by @denbezrukov in https://github.com/biomejs/biome/pull/7685
  115. * chore(deps): update pnpm to v10.18.0 by @renovate[bot] in https://github.com/biomejs/biome/pull/7693
  116. * chore(deps): update taiki-e/install-action action to v2.62.21 by @renovate[bot] in https://github.com/biomejs/biome/pull/7692
  117. * chore(deps): update rust crate camino to 1.2.1 by @renovate[bot] in https://github.com/biomejs/biome/pull/7694
  118. * fix(deps): update rust crates by @renovate[bot] in https://github.com/biomejs/biome/pull/7562
  119. * fix(lint/useExhaustiveDependencies): correct fix for method calls by @siketyan in https://github.com/biomejs/biome/pull/7709
  120. * chore(deps): update dependency @types/node to v22.18.10 by @renovate[bot] in https://github.com/biomejs/biome/pull/7738
  121. * chore(deps): update rust crate libc to 0.2.177 by @renovate[bot] in https://github.com/biomejs/biome/pull/7740
  122. * chore(deps): update rust crate ureq to 3.1.2 - autoclosed by @renovate[bot] in https://github.com/biomejs/biome/pull/7741
  123. * ci: release by @github-actions[bot] in https://github.com/biomejs/biome/pull/7637
  124. * chore(deps): update github-actions by @renovate[bot] in https://github.com/biomejs/biome/pull/7736
  125. ## New Contributors
  126. * @ritoban23 made their first contribution in https://github.com/biomejs/biome/pull/7608
  127. * @SzymCode made their first contribution in https://github.com/biomejs/biome/pull/7630
  128. * @You-saku made their first contribution in https://github.com/biomejs/biome/pull/7678
  129. **Full Changelog**: https://github.com/biomejs/biome/compare/@biomejs/biome@2.2.5...@biomejs/biome@2.2.6

vedi su githubimported 2026-09-28 via npm