UT-Registration-Plus icon indicating copy to clipboard operation
UT-Registration-Plus copied to clipboard

chore: migrate to ESLint v9 flat config and update linting tools

Open Copilot opened this issue 3 months ago • 2 comments

Migrates ESLint configuration from legacy .eslintrc.cjs format to v9 flat config format and updates all linting dependencies to latest versions.

Changes

ESLint Migration

  • Migrated from .eslintrc.cjs to eslint.config.mjs flat config format
  • Removed deprecated .eslintignore (ignores now inline in config)
  • Removed --ext flag from lint scripts (auto-detected in v9)
  • Added @eslint/compat + @eslint/eslintrc for legacy config compatibility
  • Used fixupConfigRules() to bridge airbnb-typescript/v8 incompatibility

Package Updates

  • ESLint: v8.57.1 → v9.39.1
  • @typescript-eslint/*: v7.18.0 → v8.47.0
  • eslint-config-prettier: v9.1.0 → v10.1.8
  • eslint-plugin-react-hooks: v4.6.2 → v7.0.1
  • eslint-plugin-jsdoc: v50.6.3 → v61.2.1
  • eslint-plugin-storybook: v0.9.0 → v10.0.8
  • prettier: v3.5.2 → v3.6.2
  • Plus other minor plugin updates

Configuration Example

Before (.eslintrc.cjs):

module.exports = {
  root: true,
  parser: '@typescript-eslint/parser',
  extends: ['airbnb-typescript', 'prettier'],
  // ...
}

After (eslint.config.mjs):

import { fixupConfigRules } from '@eslint/compat';
import { FlatCompat } from '@eslint/eslintrc';
import js from '@eslint/js';

export default [
  { ignores: ['dist/**', 'build/**'] },
  js.configs.recommended,
  ...fixupConfigRules(
    compat.extends('airbnb-typescript', 'prettier')
  ),
  // ...
]

All existing rules and code style preserved. Build, type-check, and linting verified.

Original prompt

Update Eslint and prettier, migrating the config format to the new version.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.


This change is Reviewable

Copilot avatar Nov 17 '25 19:11 Copilot