Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: upgrade eslint to 9.6.0 #2175

Closed
wants to merge 2 commits into from
Closed

chore: upgrade eslint to 9.6.0 #2175

wants to merge 2 commits into from

Conversation

Barsnes
Copy link
Member

@Barsnes Barsnes commented Jul 10, 2024

#1844

This is the start of migrating to eslint version 9.
We have to wait for eslint-plugin-import to support this, and possibly other plugins.
Will leave this PR open for now, so we can easily test a soon as plugins are updated to support the new config format.

Copy link
Contributor

Preview deployments for this pull request:

No deployments found.

mimarz added a commit that referenced this pull request Aug 1, 2024
**TLDR; Replace eslint and prettier (except css) for linting and
formatting.**

After doing some testing, debugging and fighting with getting eslint to
work in #2175, I made this to test biomejs as a replacement.

Either way we had to do big config changes for eslint 9.x so might
aswell try biomejs.

In general a positive experience having tested biomejs.

## Noticable changes:
- Linting is now done for the whole repo, except "ignores".
- Seperated gh workflows. 
  - Linting is now done in a separate workflow for the whole repo.
- Building and testing the individual packages or apps i their own
workflow. (will do more renames here after merging into `next`)
- New recommended vscode extension for biomejs.


## Biomejs vs Eslint
- Biomejs lints, formats and sorts import order in <1s, while eslint 8.x
uses >40s for only linting.
  - Linting when coding is also noticeably faster
- Biomejs is still limited in what can be configured, but most of its
current features set is good enough for our needs.
- Biomejs is only 1 dependency, opposed to 11 dependencies from eslint
  - No more hassle upgrading dependencies hopefully
- Biomejs lacks:
- CSS formatting, ([but its being worked
on](https://biomejs.dev/internals/language-support/)), so we are still
using prettier for this.
  - Typed-linting? (i think)
- No way of defining our own import order
([RFC](biomejs/biome#3015))
- No plugin support [but its
planned](https://biomejs.dev/blog/roadmap-2024/)
- Biomejs also has some new good linting rules we fixed
  - https://biomejs.dev/linter/rules/no-for-each/
  - https://biomejs.dev/linter/rules/no-comma-operator/
  - https://biomejs.dev/linter/rules/no-shadow-restricted-names/
  - https://biomejs.dev/linter/rules/no-useless-else/
  - https://biomejs.dev/linter/rules/no-assign-in-expressions/
  - https://biomejs.dev/linter/rules/no-accumulating-spread/
  - https://biomejs.dev/linter/rules/no-implicit-any-let/
@mimarz
Copy link
Collaborator

mimarz commented Aug 1, 2024

deprecated by #2189

@mimarz mimarz closed this Aug 1, 2024
@Barsnes Barsnes deleted the chore/eslint-9 branch August 13, 2024 10:45
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.

2 participants