Page MenuHomePhabricator

Create a WMDE-Fundraising-Eslint ruleset
Open, Needs TriagePublic

Description

We currently use a WMF maintained eslint rule set called eslint-config-wikimedia. It tends to get updated a little too slow for us and we often have to wait for it to be updated before we can update other dependencies. This is currently happening with Eslint, we're stuck on an unsupported version of v8, and we can't upgrade to v9 until eslint-config-wikimedia supports it.

We made the decision to copy and maintain our own version of this rule set so we can update it when we need.

Acceptance Criteria

  • We no longer use eslint-config-wikimedia.
  • We have a repo with our copy that we include in our javascript projects as a replacement.
  • Our linting styles don't change/are not affected by this replacement.

Implementation notes
We want to use ESLint 9.x (or greater) for the new repository. This means we have to migrate our .eslintrc file to the new eslint.config.js format. The recommended way to to this is as follows:

See https://eslint.org/blog/2022/08/new-config-system-part-1/ and https://eslint.org/blog/2022/08/new-config-system-part-2/ for more information about the background of the configuration changes and to see side-by-side comparisons between old and new code. See https://eslint.org/docs/latest/use/configure/migration-guide for the official migration guide.