ESLint 9
kutsan opened this issue ยท 24 comments
It would be awesome to add ESLint 9 support.
Waiting for all plugins to support it.
Just saw that Typescript-Eslint released they v8 yesterday.
@mightyiam when you say "all plugins" do you mean mostly the major ones, or any specific ones?
I was wondering when i could change to use ESlint 9, and love and also ts-eslint, since they are the major ones that my project runs on.
Thank you.
Two things need to happen:
- #1699 (possibly this weekend)
- one of
- import-js/eslint-plugin-import#2948
- migrating to a fork of the above
Got it, seems to be a heated discussion on eslint-plugin-import
, so a fork might be a viable solution.
I'll keep following the progress.
Thank you!
Now that we have typescript-eslint v8, the remaining blocker is eslint-plugin-import. And I'm not sure what to do about that except for waiting. The fork could work, but I feel reluctant. Any opinions?
@mightyiam perhaps we could import this plugin through compat layers as suggested in this comment?
https://github.com/eslint/rewrite/tree/9250f2842456dff373508dce50cff536e32d8686/packages/compat
usage seems trivial. I wonder though how do we know that all fixed rules still work...
Hi everyone, hi @mightyiam !
Following up with this issue I created two PRs.
Since the import
plugin seems to be the remaining step in order to move to eslint v9 here are both available solutions.
I'm afraid #1733 is a dead-end because it does not prevent this:
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: eslint-plugin-import@2.29.1
npm error Found: eslint@9.9.1
npm error node_modules/eslint
npm error dev eslint@"9.9.1" from the root project
npm error peer eslint@"^6.0.0 || ^7.0.0 || >=8.0.0" from @eslint-community/eslint-utils@4.4.0
npm error node_modules/@eslint-community/eslint-utils
npm error @eslint-community/eslint-utils@"^4.4.0" from @typescript-eslint/utils@8.2.0
npm error node_modules/@typescript-eslint/utils
npm error @typescript-eslint/utils@"8.2.0" from @typescript-eslint/eslint-plugin@8.2.0
npm error node_modules/@typescript-eslint/eslint-plugin
npm error @typescript-eslint/eslint-plugin@"8.2.0" from typescript-eslint@8.2.0
npm error node_modules/typescript-eslint
npm error 2 more (@typescript-eslint/type-utils, typescript-eslint)
npm error @eslint-community/eslint-utils@"^4.2.0" from eslint@9.9.1
npm error 3 more (eslint-plugin-es-x, eslint-plugin-n, @typescript-eslint/utils)
npm error 10 more (@typescript-eslint/eslint-plugin, ...)
npm error
npm error Could not resolve dependency:
npm error peer eslint@"^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" from eslint-plugin-import@2.29.1
npm error node_modules/eslint-plugin-import
npm error eslint-plugin-import@"^2.25.2" from the root project
npm error
npm error Conflicting peer dependency: eslint@8.57.0
npm error node_modules/eslint
npm error peer eslint@"^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" from eslint-plugin-import@2.29.1
npm error node_modules/eslint-plugin-import
npm error eslint-plugin-import@"^2.25.2" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
@mightyiam my understanding is eslint-plugin-import
would rather rewrite to eslint v9 than just patch with the compat utils.
You can see that works is in progress at import-js/eslint-plugin-import#2996
I'm afraid it might take a long time and I think I can't do much more than this to PRs in the mean time, but let me know!
What about waiting for ESLint v9 support in eslint-plugin-import?
@mightyiam eslint-plugin-import just dropped a new release supporting flat configs.
any updates on eslint 9 support?
It looks like there will be movement on that on the eslint-plugin-import side shortly!
import-js/eslint-plugin-import#3061 just got approved, which is blocking for import-js/eslint-plugin-import#2996. The latter should fix v9 support.
any updates on eslint 9 support?
Hey, sorry for not responding to this. Not sure how I missed it.
Yes, what @TyIsI wrote.
Hi, I was just setting up a project and saw that import-js/eslint-plugin-import#2996 was merged just a few minutes ago, so nothing should block the ESLint 9 support now (after it's been released of course) ๐
A new eslint-plugin-import version has been released that supports eslint 9 now!
https://github.com/import-js/eslint-plugin-import/releases/tag/v2.31.0
@mightyiam The package.json should be updated to reflect this
- "eslint": "^8.0.1",
+ "eslint": ">=8.0.1",
But this would fail dependencies tests
@pnodet "eslint": "^8.0.1"
is currently correct.
https://jubianchi.github.io/semver-check/#/^8.0.1/8.1.0
https://jubianchi.github.io/semver-check/#/^8.0.1/9.0.0
Oh, wait. I missed #1589 (comment)
๐ฅ