Closed renovate[bot] closed 6 months ago
Latest commit: ba890e170b10952416be75aaa90aedb960920d71
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
This PR contains the following updates:
1.6.1
->1.7.1
Release Notes
biomejs/biome (@biomejs/biome)
### [`v1.7.1`](https://togithub.com/biomejs/biome/blob/HEAD/CHANGELOG.md#171-2024-04-22) [Compare Source](https://togithub.com/biomejs/biome/compare/2dce6af835cc9339669b09f3a758de36a90b15f7...aba7b0c1c40a6137b3b78064841f621b53aa5fd0) ##### Editors ##### Bug fixes - Fix [#2403](https://togithub.com/biomejs/biome/issues/2403) by printing the errors in the client console. Contributed by [@ematipico](https://togithub.com/ematipico) ##### Formatter ##### Bug fixes - Add parentheses for the return expression that has leading multiline comments. [#2504](https://togithub.com/biomejs/biome/pull/2504). Contributed by [@ah-yu](https://togithub.com/ah-yu) - Correctly format dangling comments of continue statements. [#2555](https://togithub.com/biomejs/biome/pull/2555). Contributed by [@ah-yu](https://togithub.com/ah-yu) ##### Linter ##### Bug fixes - Fix case where `jsxRuntime` wasn't being respected by `useImportType` rule ([#2473](https://togithub.com/biomejs/biome/issues/2473)).Contributed by [@arendjr](https://togithub.com/arendjr) - Fix [#2460](https://togithub.com/biomejs/biome/issues/2460), where the rule `noUselessFragments` was crashing the linter in some cases. Now cases like these are correctly handled: ```jsx callFunction(<>{bar}>) ``` Contributed by [@ematipico](https://togithub.com/ematipico) - Fix [#2366](https://togithub.com/biomejs/biome/issues/2366), where `noDuplicateJsonKeys` incorrectly computed the kes to highlight. Contributed by [@ematipico](https://togithub.com/ematipico) ##### Enhancements - The rule `noMisplacedAssertions` now considers valid calling `expect` inside `waitFor`: ```js import { waitFor } from '@testing-library/react'; await waitFor(() => { expect(111).toBe(222); }); ``` Contributed by [@ematipico](https://togithub.com/ematipico) ### [`v1.7.0`](https://togithub.com/biomejs/biome/blob/HEAD/CHANGELOG.md#170-2024-04-15) [Compare Source](https://togithub.com/biomejs/biome/compare/f6fd1ef7130e7bcd1466aa78ae7295fc5fdd5d58...2dce6af835cc9339669b09f3a758de36a90b15f7) ##### Analyzer ##### Bug fixes - Now Biome can detect the script language in Svelte and Vue script blocks more reliably ([#2245](https://togithub.com/biomejs/biome/issues/2245)). Contributed by [@Sec-ant](https://togithub.com/Sec-ant) - `useExhaustiveDependencies` no longer reports recursive calls as missing dependencies ([#2361](https://togithub.com/biomejs/biome/issues/2361)). Contributed by [@arendjr](https://togithub.com/arendjr) - `useExhaustiveDependencies` correctly reports missing dependencies declared using function declarations ([#2362](https://togithub.com/biomejs/biome/issues/2362)). Contributed by [@arendjr](https://togithub.com/arendjr) - Biome now can handle `.svelte` and `.vue` files with `CRLF` as the end-of-line sequence. Contributed by [@Sec-ant](https://togithub.com/Sec-ant) - `noMisplacedAssertion` no longer reports method calls by `describe`, `test`, `it` objects (e.g. `test.each([])()`) ([#2443](https://togithub.com/biomejs/biome/issues/2443)). Contributed by [@unvalley](https://togithub.com/unvalley). - Biome now can handle `.vue` files with [generic components](https://vuejs.org/api/sfc-script-setup#generics) ([#2456](https://togithub.com/biomejs/biome/issues/2456)). ```vue ``` Contributed by [@Sec-ant](https://togithub.com/Sec-ant) ##### Enhancements - Complete the well-known file lists for JSON-like files. Trailing commas are allowed in `.jsonc` files by default. Some well-known files like `tsconfig.json` and `.babelrc` don't use the `.jsonc` extension but still allow comments and trailing commas. While others, such as `.eslintrc.json`, only allow comments. Biome is able to identify these files and adjusts the `json.parser.allowTrailingCommas` option accordingly to ensure they are correctly parsed. Contributed by [@Sec-ant](https://togithub.com/Sec-ant) - Fix dedent logic inconsistent with prettier where the indent-style is space and the indent-width is not 2. Contributed by [@mdm317](https://togithub.com/mdm317) ##### CLI ##### New features - Add a command to migrate from ESLint `biome migrate eslint` allows you to migrate an ESLint configuration to Biome. The command supports [legacy ESLint configurations](https://eslint.org/docs/latest/use/configure/configuration-files) and [new flat ESLint configurations](https://eslint.org/docs/latest/use/configure/configuration-files-new). Legacy ESLint configurations using the YAML format are not supported. When loading a legacy ESLint configuration, Biome resolves the `extends` field. It resolves both shared configurations and plugin presets! To do this, it invokes *Node.js*. Biome relies on the metadata of its rules to determine the [equivalent rule of an ESLint rule](https://biomejs.dev/linter/rules-sources/). A Biome rule is either inspired or roughly identical to an ESLint rules. By default, inspired and nursery rules are excluded from the migration. You can use the CLI flags `--include-inspired` and `--include-nursery` to migrate them as well. Note that this is a best-effort approach. You are not guaranteed to get the same behavior as ESLint. Given the following ESLint configuration: ```json { "ignore_patterns": ["**/*.test.js"], "globals": { "var2": "readonly" }, "rules": { "eqeqeq": "error" }, "overrides": [{ "files": ["lib/*.js"], "rules": { "default-param-last": "off" } }] } ``` `biome migrate eslint --write` changes the Biome configuration as follows: ```json { "linter": { "rules": { "recommended": false, "suspicious": { "noDoubleEquals": "error" } } }, "javascript": { "globals": ["var2"] }, "overrides": [{ "include": ["lib/*.js"], "linter": { "rules": { "style": { "useDefaultParameterLast": "off" } } } }] } ``` Also, if the working directory contains `.eslintignore`, then Biome migrates the glob patterns. Nested `.eslintignore` in subdirectories and negated glob patterns are not supported. If you find any issue, please don't hesitate to report them. Contributed by [@Conaclos](https://togithub.com/Conaclos) - Added two new options to customise the emitted output of the CLI: `--reporter=json` and `--reporter=json-pretty`. With `--reporter=json`, the diagnostics and the summary will be printed in the **terminal** in JSON format. With `--reporter=json-pretty`, you can print the same information, but formatted using the same options of your configuration. NOTE: the shape of the JSON is considered experimental, and the shape of the JSON might change in the future.Example of output when running `biome format` command
```json { "summary": { "changed": 0, "unchanged": 1, "errors": 1, "warnings": 0, "skipped": 0, "suggestedFixesSkipped": 0, "diagnosticsNotPrinted": 0 }, "diagnostics": [ { "category": "format", "severity": "error", "description": "Formatter would have printed the following content:", "message": [ { "elements": [], "content": "Formatter would have printed the following content:" } ], "advices": { "advices": [ { "diff": { "dictionary": " statement();\n", "ops": [ { "diffOp": { "delete": { "range": [0, 2] } } }, { "diffOp": { "equal": { "range": [2, 12] } } }, { "diffOp": { "delete": { "range": [0, 2] } } }, { "diffOp": { "equal": { "range": [12, 13] } } }, { "diffOp": { "delete": { "range": [0, 2] } } }, { "diffOp": { "insert": { "range": [13, 15] } } } ] } } ] }, "verboseAdvices": { "advices": [] }, "location": { "path": { "file": "format.js" }, "span": null, "sourceCode": null }, "tags": [], "source": null } ], "command": "format" } ```Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), 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.
This PR has been generated by Mend Renovate. View repository job log here.