Skip to content

chore: replace eslint/dprint with biome#396

Merged
steabert merged 1 commit intomainfrom
stevenv/biome
Feb 25, 2025
Merged

chore: replace eslint/dprint with biome#396
steabert merged 1 commit intomainfrom
stevenv/biome

Conversation

@steabert
Copy link
Member

@steabert steabert commented Feb 10, 2025

Removes eslint and adds biome, which is a much faster linter
that can handle TypeScript out of the box, and also does formatting.

NOTE:

  • dprint is gone (as biome does formatting by itself, and it covers our source code)
  • biome-ignore was added where it gave an error (mostly exhaustive dependencies) as I did not want to change any logic in this PR, but I've marked them with FIXME (they either need a proper reason, or a fix)
  • there is a single config file which tried to match the original format as close as possible, and I've only added the lint rules that actually affect correctness (no opinionated shenanigans about code style) with some exceptions that we also use to avoid too many inline ignores
  • there was a problem with circular dependencies connected to the route map, this caused issues with HMR depending on the order of imports. The circular dependencies are now removed but it might be good in the future to add a check for this.

WANTED:

  • some more testing using VS Code (It worked on my machine but I rarely use it so it's good if someone else can try it out that hasn't used biome before)

@steabert steabert requested a review from a team as a code owner February 10, 2025 15:56
@steabert steabert self-assigned this Feb 10, 2025
@steabert steabert changed the title Stevenv/biome chore: replace eslint/dprint with biome Feb 10, 2025
@steabert steabert force-pushed the stevenv/biome branch 3 times, most recently from 692c6df to bc12bbf Compare February 11, 2025 07:45
@steabert steabert force-pushed the stevenv/biome branch 2 times, most recently from ba43c61 to 42f7d43 Compare February 19, 2025 15:16
@lekoaf
Copy link
Member

lekoaf commented Feb 20, 2025

image

Unknown if this is a me or you issue. 😃

@lekoaf
Copy link
Member

lekoaf commented Feb 20, 2025

Format command works well for me. Also the dev enviroment still runs. So besides the issue above, LGTM.

Removes eslint and adds biome, which is a much faster linter
that can handle TypeScript out of the box, and also does formatting.

Removes circular dependencies related to importing elements into the
route map, but also route map into elements. This caused a problem
with vite's HMR depending on the exact order of the imports.
The solution here is to only map routes to elements where needed
(in this case only App.tsx).
@steabert steabert merged commit 52ecb1f into main Feb 25, 2025
4 checks passed
@steabert steabert deleted the stevenv/biome branch February 25, 2025 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants