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

v4: move to flat config, support ESLint v9 and friends, migrate plugins, and more #348

Draft
wants to merge 40 commits into
base: main
Choose a base branch
from

Conversation

G-Rath
Copy link
Contributor

@G-Rath G-Rath commented Nov 28, 2024

This is branched off #347


This does a bunch of updates to our configs in the name of supporting ESLint v9 and the new flat configuration system - in the process, I've also migrated some deprecated plugins, removed our flowtype config as we don't want anyone doing Flow, renamed the @typescript-eslint config to typescript, and more.

I've structured each commit with a description of the change and migration notes where needed, and there's already been discussion in our internal Slack so I won't repeat stuff in this description 🙂

G-Rath and others added 19 commits December 3, 2024 07:48
BREAKING CHANGE: ESLint v7 is no longer supported
BREAKING CHANGE: `@typescript-eslint/*` v6 is no longer supported
BREAKING CHANGE: `eslint-plugin-jest` v27 is no longer supported
…omments`

The maintainer of the original plugin has disappeared, so the community have launched a fork.

Migration:
  1. Remove `eslint-plugin-eslint-comments` dependency
  2. Add `@eslint-community/eslint-plugin-eslint-comments` dependency
  3. Replace any references to `eslint-comments` in `.eslintrc.js` and comments (such as ignore
  directives) with `@eslint-community/eslint-comments`

BREAKING CHANGE
The maintainer of the original plugin has disappeared, so the community have launched a fork.

Migration:
  1. Remove `eslint-plugin-node` dependency
  2. Add `eslint-plugin-n` dependency
  3. Replace any references to `node` in `.eslintrc.js` and comments (such as ignore directives)
  with `n`

BREAKING CHANGE
BREAKING CHANGE: you must now install `@stylistic/eslint-plugin-js`
BREAKING CHANGE: you must now install `@stylistic/eslint-plugin-ts`
TypeScript has won and `eslint-plugin-flowtype` hasn't been updated in years so doesn't support
ESLint v9.

BREAKING CHANGE: `flowtype` config is no longer available
BREAKING CHANGE: configs are now flat by default, unless `ESLINT_USE_FLAT_CONFIG` is `'false'`
BREAKING CHANGE: you must now ensure `@eslint/js` is installed
BREAKING CHANGE: you must now use `typescript` instead of `@typescript-eslint`
…` v7

For some reason without this we get errors about strict null checks not being enabled from the
TypeScript config, but only _after_ it's renamed to `typescript` and if `process.env.CI` is `true`
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.

1 participant