Open
Conversation
Drop eslint, @eslint/js, eslint-config-prettier, globals, and prettier. Add @biomejs/biome. biome.json carries over the same formatter settings (120 char width, single quotes, no semicolons, no trailing commas) and uses Biome's recommended lint rules with the ones we weren't enforcing before turned off. noUnusedVariables is set to warn since Biome doesn't support argsIgnorePattern. Lint scripts now use 'biome check .' instead of running prettier and eslint separately. VS Code config points at the Biome extension.
Mechanical changes from biome check --write: - let -> const where never reassigned (useConst) - const self = this removed, self. -> this. (noUselessThisAlias) - parseInt -> Number.parseInt (useNumberNamespace) - function expressions -> arrow functions (useArrowFunction) - for (let x of ...) -> for (const x of ...) 33 files, all safe transforms. No behavior changes.
81bbf78 to
af5f09c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Swaps out ESLint 10, Prettier 3.8, and the three config files holding them together for Biome and a single biome.json. Five fewer devDependencies.
The formatter settings match what we had -- 120 char width, single quotes, no semicolons, no trailing commas. Biome's recommended lint rules are on, with anything we weren't already enforcing disabled (can turn those on later in separate PRs).
noUnusedVariablesis set to warn since Biome doesn't have ESLint'sargsIgnorePattern.npm run lintnow runsbiome check .instead of prettier + eslint as two separate commands. CI doesn't need changes since it just callsnpm test.Split into two commits for easier review:
let->const, removeselfaliases,Number.parseInt, arrow functions). All mechanical, no behavior changes.See also clearlydefined/service#1500