-
Notifications
You must be signed in to change notification settings - Fork 235
Upgrade eslint to v9 with newer recommended configs #1760
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
Conversation
|
size-limit report 📦
|
1egoman
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This generally makes sense to me!
Note that the tests aren't passing, at least in the most recent CI run as of this review it is because of the below (and it looks related to this change). Once the below is fixed I'll approve this!
> [email protected] compat /home/runner/work/client-sdk-js/client-sdk-js
> eslint --no-eslintrc --config ./.eslintrc.dist.cjs ./dist/livekit-client.umd.js
Invalid option '--eslintrc' - perhaps you meant '--ext'?
You're using eslint.config.js, some command line flags are no longer available. Please see https://eslint.org/docs/latest/use/command-line-interface for details.
ELIFECYCLE Command failed with exit code 2.
|
the failing test was the one that runs on the "compiled" output dist. The plugin was no longer maintained so I now switched us to a different one that seems to have better feature detection as well! Should be good to go now |
this PR adopts the new flat file config for eslint and uses the airbnb-typescript-extended plugin (as the old airbnb typescript one doesn't get updates anymore).
With this change we now also get linting with type information.
The only downside is that the linting job takes a bit longer (because TS is additionally running).
I added a minimal set of ignored rules for now so that the lint job still passes with the current code base. We can then do smaller PRs to address individual rules.