Upgrading to Ultracite v5
Ultracite v5 moved to Biome 2, whose configuration format differs from Biome 1's. Every later release uses Biome 2 too.
Does the project need it?
Yes, if the Biome config (biome.json or biome.jsonc) still uses Biome 1's format: its $schema points at a 1.x schema (such as https://biomejs.dev/schemas/1.9.4/schema.json), or it has a top-level organizeImports, files.ignore or files.include.
Steps
Set
$schemato./node_modules/@biomejs/biome/configuration_schema.json. Leave"extends": ["ultracite"]as it is; the v6 and v7 guides rename it.Move Biome 1 settings to their Biome 2 form:
files.ignoreandfiles.includebecome a singlefiles.includeslist. Start it with"**", then add each ignored path with a leading!. Globs no longer get an implicit**/prefix, so an ignoreddistbecomes"!**/dist".organizeImportsmoves toassist.actions.source.organizeImports, set to"on"or"off".linter.rules.allis gone, with no replacement. Remove it.- Paths and globs are now relative to the config file, not the folder Biome runs in.
If you can run commands,
npx @biomejs/biome migrate --writemakes most of these changes. Review what it writes.Biome 2 reads suppression comments as
// biome-ignore lint/<group>/<rule>: <reason>. Rewrite any in the oldlint(<group>/<rule>)form.biome.jsonkeeps working. v5 wrotebiome.jsoncfor new projects, but there's no need to rename an existing file.
Check
npx ultracite check runs without a configuration error.