Skip to content

πŸ› Reformatting doesn't work in an IntelliJ project with multiple modulesΒ #180

@donalmurtagh

Description

@donalmurtagh

IDE and version

IntelliJ 2025.1.2 (Ultimate Edition)

Extension version

1.7.2

Biome version

2.0.0

Operating system

  • Windows
  • macOS
  • Linux

Description

When I try to reformat a file via the hotkey βŒ₯β‡§βŒ˜+L, the Biome formatter options are ignored. Instead, the options configured in Editor | Code Style | JavaScript are used.

It seems the root cause is that the Biome language service is never active for the files that it should support: .vue, .js, etc.

Steps to reproduce

  1. Setup an IntelliJ project with biome-web-module and java-module as separate modules as per the reproduction repository
  2. Install the Biome IntelliJ plugin if necessary
  3. In the Biome IntelliJ settings, enable Biome and "Enable LSP-based code formatting"
  4. Notice that the Biome language service does not run when biome-web-module/src/script.js is opened, so reformatting with Biome doesn't work
  5. Remove the java-module module from the project
  6. Re-open biome-web-module/src/script.js and you should see that the Biome language service is now running, so reformatting with Biome does work

Expected behavior

When an eligible file (JavaScript, TypeScript, etc.) in any module with a biome config file is opened, the Biome language service should run, thus enabling reformatting with Biome.

The number of modules in the project shouldn't make any difference to the behaviour.

Does this issue occur when using the CLI directly?

Not sure / Not applicable

Link to a minimal reproduction

https://github.com/donalmurtagh/multi-module-project/

Metadata

Metadata

Assignees

Labels

Bug confirmedReport has been confirmed as a valid bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions