chore!: next.js 16 prep: bump eslint-config-next + @next/eslint-plugin-next to v16 (#932)#939
Merged
Merged
Conversation
…-next to v16 (#932) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the repository’s linting toolchain as part of the Next.js 16 upgrade plan by bumping eslint-config-next/@next/eslint-plugin-next to v16 (requiring ESLint 9) and adjusting the flat-config setup and plugin set to remain functional under ESLint 9.
Changes:
- Bump ESLint core + Next ESLint config/plugin to v16 and update the supporting ESLint plugin stack for ESLint 9 compatibility.
- Update
eslint.config.mjsto direct-import Next + SonarJS flat configs, replace deprecated plugins (eslint-comments fork, sort-keys plugin replacement), and reapply/adjust rules. - Remove stale
eslint-disabledirectives across the codebase now that ESLint 9 reports unused disables by default.
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
eslint.config.mjs |
Updates flat-config composition (direct Next + SonarJS configs), swaps plugins (perfectionist, eslint-comments fork), and adjusts rules for ESLint 9. |
package.json |
Bumps ESLint/Next ESLint packages and updates/replaces several ESLint plugins; simplifies lint script for ESLint 9 flat-config default. |
package-lock.json |
Locks the updated ESLint/Next lint stack and transitive dependency changes. |
src/theme/common/components.ts |
Removes now-unused sort-keys disable comments. |
src/providers/fileManifestState.tsx |
Removes unused no-empty-function disable. |
src/providers/exploreState.tsx |
Removes unused no-empty-function disable. |
src/entity/service/model.ts |
Removes an unused no-explicit-any disable in a signature where it no longer applies. |
src/config/utils.ts |
Removes an unused no-explicit-any disable in a signature where it no longer applies. |
src/components/Table/common/utils.ts |
Removes unused no-empty-function disable in a callback config object. |
src/components/MarkdownRenderer/rehypeHighlight.ts |
Removes unused sonarjs/cognitive-complexity disable. |
src/components/Index/table/hook.ts |
Removes unused inline sonarjs/cognitive-complexity disable. |
src/components/Filter/components/adapters/tanstack/ColumnFiltersAdapter/columnFiltersAdapter.tsx |
Removes unused no-unused-vars disables where underscore-prefixed args are already ignored. |
src/components/common/Paper/paper.styles.ts |
Removes legacy valid-jsdoc disable/enable comments (rule no longer relevant). |
eslint-plugin-jsdoc@63 requires node ^22.13.0 || >=24; bumping the repo pin and CI workflows to a same-LTS patch release satisfies the engine constraint without other behavior change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sync README, CLAUDE.md, and trusted-publishing doc with the bumped node pin. CHANGELOG entries left as historical record. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
NoopDog
approved these changes
May 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Part of #884 (Next.js 16 upgrade plan).
Bumps
eslint-config-next+@next/eslint-plugin-nextto v16, which forces ESLint 8→9, which cascades into multiple plugin updates required to keep the lint stack working under flat-config + ESLint 9.Core bumps
eslint:^8.57.1→^9@eslint/js:^8.57.1→^9eslint-config-next:^15.5.13→^16@next/eslint-plugin-next:^15.5.13→^16ESLINT_USE_FLAT_CONFIG=trueenv-var prefix from the lint script (ESLint 9 makes flat config the default).Plugin cascade (forced by ESLint 9 compat)
eslint-plugin-sonarjs:^0.25.1→^1(v0.25 uses removedcontext.getScopeAPI).eslint-plugin-react-hooks:^5.2.0→^7.eslint-plugin-sort-destructure-keys:^2→^3(peer range widened to ESLint 9/10).eslint-plugin-jsdoc:^61.5.0→^63.@typescript-eslint/eslint-plugin:^8.50.0→^8.59.0(minor).Plugin replacements
eslint-plugin-typescript-sort-keys→eslint-plugin-perfectionist(the former is abandoned; pinned to ESLint 7-8). Replaces our two rules:typescript-sort-keys/interface→perfectionist/sort-interfacestypescript-sort-keys/string-enum→perfectionist/sort-enumseslint-plugin-eslint-comments→@eslint-community/eslint-plugin-eslint-comments(community fork; the original was last released in 2022 and uses old ESLint internals). Drop-in (rule names unchanged:@eslint-community/eslint-comments/require-description).Flat-config adjustments
eslint-config-nextv16 ships a native flat config that doesn't roundtrip cleanly throughFlatCompat(circular JSON during schema validation). Direct-imported asimport next from "eslint-config-next"and spread before thecompat.config(...)block.eslint-plugin-sonarjsv1 same situation. Direct-imported asimport sonarjs from "eslint-plugin-sonarjs"and added assonarjs.configs.recommended.Node version bump
22.12.0→22.13.0(package.json#engines+ 3 CI workflow refs + Copilot instructions doc).eslint-plugin-jsdoc@63requiresnode ^22.13.0 || >=24; staying on22.12.0would emitEBADENGINEwarnings. Same LTS line, patch-level bump only.Rule-set notes
react-hooksv7 rules disabled. v7 ships React-Compiler-aware checks (refs,immutability,set-state-in-effect,incompatible-library,static-components) that surface ~20 real anti-patterns across the codebase. These are out of scope for a tooling PR — disabled here with a comment, follow-up ticket to be filed.sonarjs/cognitive-complexityrestored explicitly at threshold 15. sonarjs v1'srecommendedpreset silently dropped this rule (the rule'smeta.docs.recommendedflag was lost during the v1 rewrite, a discrepancy with the package README). Restoring preserves the coverage we had under v0.25. Documented in an inline comment.Source-file changes (pure cleanup, no behavior change)
ESLint 9 enables
report-unused-disable-directivesby default.--fixremoved several staleeslint-disablecomments that were orphans from past refactors:valid-jsdoc(rule removed in ESLint 9),@typescript-eslint/no-explicit-any(theanyhad been taken out of the code),@typescript-eslint/no-empty-function(function bodies no longer empty in a way the rule cares about),sort-keys(keys had been alphabetized at some point).Test plan
npm run lint— clean (one pre-existingno-html-link-for-pagesinformational notice from@next/eslint-plugin-next— findable-ui is a library, not an app)npm run check-format— cleannpm run test-compile— cleannpm test— 447/447 passfran/x-nextjs-test, anvil-cmg dev) — dev server compiles + runs cleanly against the patched findable-uiCompatibility scope (revised)
This PR lands a stack compatible with ESLint 9. Forward-compat with ESLint 10 will require additional work:
eslint-plugin-sonarjs@1only declares peer support for^8 || ^9— a bump toeslint-plugin-sonarjs@4(or whichever version officially adds v10) will be needed before adopting ESLint 10. Filing as a follow-up.Closes #932