github biomejs/biome lsp/v1.5.20231006
VSCode Extension v1.5.20231006

pre-release11 months ago

Analyzer

Enhancements

  • Import sorting is safe to apply now, and it will be applied when running check --apply instead of check --apply-unsafe.

CLI

Bug fixes

  • Fix #319. The command biome lint now shows the correct options. Contributed by @ematipico
  • Fix #312. Running biome --version now exits with status code 0 instead of 1. Contributed by @nhedger
  • Fix a bug where the extends functionality doesn't carry over organizeImports.ignore. Contributed by @ematipico

New features

  • Add support for BIOME_BINARY environment variable to override the location of the binary. Contributed by @ematipico

  • Add option --indent-width, and deprecated the option --indent-size. Contributed by @ematipico

  • Add option --javascript-formatter-indent-width, and deprecated the option --javascript-formatter-indent-size. Contributed by @ematipico

  • Add option --json-formatter-indent-width, and deprecated the option --json-formatter-indent-size. Contributed by @ematipico

  • Add option --daemon-logs to biome rage. The option is required to view Biome daemon server logs. Contributed by @unvalley

  • Add support for logging. By default, Biome doesn't log anything other than diagnostics. Logging can be enabled with the new option --log-level:

    biome format --log-level=info ./src

    There are four different levels of logging, from the most verbose to the least verbose: debug, info, warn and error. Here's how an INFO log will look like:

    2023-10-05T08:27:01.954727Z  INFO  Analyze file ./website/src/playground/components/Resizable.tsx
      at crates/biome_service/src/file_handlers/javascript.rs:298 on biome::worker_5
      in Pulling diagnostics with categories: RuleCategories(SYNTAX)
      in Processes formatting with path: "./website/src/playground/components/Resizable.tsx"
      in Process check with path: "./website/src/playground/components/Resizable.tsx"
    

    You can customize how the log will look like with a new option --log-kind. The supported kinds are: pretty, compact and json.

    pretty is the default logging. Here's how a compact log will look like:

    2023-10-05T08:29:04.864247Z  INFO biome::worker_2 Process check:Processes linting:Pulling diagnostics: crates/biome_service/src/file_handlers/javascript.rs: Analyze file ./website/src/playground/components/Resizable.tsx path="./website/src/playground/components/Resizable.tsx" path="./website/src/playground/components/Resizable.tsx" categories=RuleCategories(LINT)
    2023-10-05T08:29:04.864290Z  INFO biome::worker_7 Process check:Processes formatting: crates/biome_service/src/file_handlers/javascript.rs: Format file ./website/src/playground/components/Tabs.tsx path="./website/src/playground/components/Tabs.tsx" path="./website/src/playground/components/Tabs.tsx"
    2023-10-05T08:29:04.879332Z  INFO biome::worker_2 Process check:Processes formatting:Pulling diagnostics: crates/biome_service/src/file_handlers/javascript.rs: Analyze file ./website/src/playground/components/Resizable.tsx path="./website/src/playground/components/Resizable.tsx" path="./website/src/playground/components/Resizable.tsx" categories=RuleCategories(SYNTAX)
    2023-10-05T08:29:04.879383Z  INFO biome::worker_2 Process check:Processes formatting: crates/biome_service/src/file_handlers/javascript.rs: Format file ./website/src/playground/components/Resizable.tsx path="./website/src/playground/components/Resizable.tsx" path="./website/src/playground/components/Resizable.tsx"
    

Enhancements

  • Deprecated the environment variable ROME_BINARY. Contributed by @ematipico
  • Biome doesn't check anymore the presence of the .git folder when VCS support is enabled. Contributed by @ematipico

Configuration

New features

  • Add option formatter.indentWidth, and deprecated the option formatter.indentSize. Contributed by @ematipico
  • Add option javascript.formatter.indentWidth, and deprecated the option javascript.formatter.indentSize. Contributed by @ematipico
  • Add option json.formatter.indentWidth, and deprecated the option json.formatter.indentSize. Contributed by @ematipico
  • Add option include to multiple sections of the configuration
    • files.include;
    • formatter.include;
    • linter.include;
    • organizeImports.include;
      When include and ignore are both specified, ignore takes precedence over include

Editors

Bug fixes

  • Fix #404. Biome intellij plugin now works on Windows. Contributed by @victor-teles

  • Fix #402. Biome format on intellij plugin now recognize biome.json. Contributed by @victor-teles

Formatter

Enhancements

  • Use OnceCell for the Memoized memory because that's what the RefCell<Option> implemented. Contributed by @denbezrukov

JavaScript APIs

Linter

Bug fixes

New features

Enhancements

Bug fixes

Parser

  • Enhance diagnostic for infer type handling in the parser. The 'infer' keyword can only be utilized within the 'extends' clause of a conditional type. Using it outside of this context will result in an error. Ensure that any type declarations using 'infer' are correctly placed within the conditional type structure to avoid parsing issues. Contributed by @denbezrukov

  • Add support for parsing trailing commas inside JSON files:

    {
      "json": {
        "parser": {
          "allowTrailingCommas": true
        }
      }
    }

    Contributed by @nissy-dev

VSCode

What's Changed

Other changes

  • chore: improve diagnostic message for noRedundantRoles by @DerTimonius in #367
  • fix(workflow/release_lsp): added prerelease output by @victor-teles in #379
  • chore: add CBS reference to docs and bug template by @ematipico in #345
  • chore: add nissy-dev to core contributor by @nissy-dev in #386
  • chore(js_analyze): bolster noAccumulatingSpread against false positives by @Vivalldi in #330
  • test(lint): update snapshots by @Conaclos in #388
  • chore: enable more clippy rules by @Conaclos in #369
  • feat(biome_js_analyze): noInvalidNewBuiltin by @lucasweng in #375
  • refactor: enable more Clippy rules by @Conaclos in #399
  • chore: update cargo manifest for publishing by @nissy-dev in #396
  • refactor: enable more Clippy rules by @Conaclos in #405
  • refactor(lint/noInvalidNewBuiltin): separate examples by @Conaclos in #407
  • chore: add denbezrukov to core contributor by @denbezrukov in #414
  • docs: add explanation how to break down import groups by @ematipico in #417
  • chore: improve diagnostic message for noHeaderScope by @vasucp1207 in #401
  • docs: improve documentation for check and ci commands by @ematipico in #418
  • docs(CONTRIBUTING): add victor-teles to maintainers by @victor-teles in #421
  • fix(lint/noMultipleSpacesInRegularExpressionLiterals): handle invalid range as regular chars by @Conaclos in #422
  • refactor(lint/useValidForDirection): remove rule's state by @Conaclos in #423
  • docs: improve list of rules, add data to rules metadata by @ematipico in #426
  • refactor(lint/noAriaUnsupportedElements): improve diagnostic by @vasucp1207 in #442
  • docs: npx biome -> npx @biomejs/biome by @nikeee in #447
  • chore: update website dependencies by @ematipico in #446
  • feat(css_parser): CSS Parser #268 by @denbezrukov in #438
  • chore(FUNDING): add sponsor button by @Conaclos in #453
  • docs: add documentation for setup-biome by @nhedger in #439
  • refactor(biome_js_analyze): add browser globals by @cristianl in #465
  • fix(playground): indent width is not being applied by @victor-teles in #470
  • refactor(lint/noPositiveTabindexValue): diagnostic action of noPositiveTabindexValue by @vasucp1207 in #461
  • fix(vscode): unknown command when running biome with space separated username or directories by @kraken-afk in #466
  • refactor(biome_js_analyze): enable clippy::needless_pass_by_value by @Conaclos in #464
  • chore: publish some crates and add add workflow for publish crates by @nissy-dev in #444
  • chore: change the running condition of crate release job by @nissy-dev in #471
  • docs: fix biome schema version on configuration page by @unvalley in #473
  • feat(website): add mastodon official account by @ematipico in #478
  • chore: update CONTRIBUTING.md by @nissy-dev in #472
  • fix(formatter/member-chain): regex formatting by @victor-teles in #474
  • refactor(linter): UseValidAriaProps diagnostic actions by @vasucp1207 in #479
  • docs: better guidelines for documentation rules by @ematipico in #481
  • refactor: use better data structure for useValidAriaProps by @ematipico in #480
  • feat(migrate): add migration for indentWidth by @ematipico in #476
  • feat(core): cache file features, to avoid re-computation by @ematipico in #477
  • fix(lint): unintended misprints in noSvgWithoutTitle and useButtonType lint messages by @unvalley in #485
  • feat(css_parser): CSS Parser #268 by @denbezrukov in #460
  • fix(playground): fix playground styles by @vasucp1207 in #490
  • refactor(js_semantic): minor changes by @Conaclos in #494
  • fix(vscode): biome resolution by @nhedger in #492
  • ci(release_lsp): remove unknown job dependency by @nhedger in #496

New Contributors

Full Changelog: lsp-intellij/v0.0.3...lsp/v1.5.20231006

Don't miss a new biome release

NewReleases is sending notifications on new releases.