Skip to content
Discussion options

You must be logged in to vote

You can disable import sorting using a suppression comment on the first import:

// biome-ignore assist/source/organizeImports: organized by hand
import B from "b";
import A from "a";

As demonstrated in the playground, the imports are not organized (See the "Analyzer Fixes" tab).

Otherwise, you can add an override in the biome config file and disable organizeImports for a given file:

{
  "overrides": [{
    "includes": ["src/barrel-file.js"],
    "assist": {
      "actions": {
        "organizeImports": "off"
      }
    }
  }]
}

biome fix --write

Do you mean biome lint --write?
biome lint and biome format doesn't organize imports.
biome check does.
If you run biome check --write, it wil…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@lukepighetti
Comment options

Answer selected by lukepighetti
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants