fix(eslint-plugin): [no-extraneous-class] handle index signatures#12142
fix(eslint-plugin): [no-extraneous-class] handle index signatures#12142JoshuaKGoldberg merged 1 commit intotypescript-eslint:mainfrom
Conversation
|
Thanks for the PR, @SeolJaeHyeok! typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community. The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately. Thanks again! 🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint. |
✅ Deploy Preview for typescript-eslint ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
View your CI Pipeline Execution ↗ for commit 23afe9a
☁️ Nx Cloud last updated this comment at |
JoshuaKGoldberg
left a comment
There was a problem hiding this comment.
Well that was straightforward. Nice! 😄
Thanks for your review😃 |
edb90eb
into
typescript-eslint:main
| datasource | package | from | to | | ---------- | -------------------------------- | ------ | ------ | | npm | @typescript-eslint/eslint-plugin | 8.56.0 | 8.58.0 | | npm | @typescript-eslint/parser | 8.56.0 | 8.58.0 | ## [v8.58.0](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8580-2026-03-30) ##### 🚀 Features - support TypeScript 6 ([#12124](typescript-eslint/typescript-eslint#12124)) ##### 🩹 Fixes - **eslint-plugin:** \[prefer-regexp-exec] avoid fixing unknown RegExp flags ([#12161](typescript-eslint/typescript-eslint#12161)) - **eslint-plugin:** \[no-extraneous-class] handle index signatures ([#12142](typescript-eslint/typescript-eslint#12142)) - **eslint-plugin:** crash in `no-unnecessary-type-arguments` ([#12163](typescript-eslint/typescript-eslint#12163)) ##### ❤️ Thank You - ej shafran [@ej-shafran](https://github.com/ej-shafran) - Evyatar Daud [@StyleShit](https://github.com/StyleShit) - GG ZIBLAKING - milkboy2564 [@SeolJaeHyeok](https://github.com/SeolJaeHyeok) - teee32 [@teee32](https://github.com/teee32) See [GitHub Releases](https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.58.0) for more information. You can read about our [versioning strategy](https://typescript-eslint.io/users/versioning) and [releases](https://typescript-eslint.io/users/releases) on our website. ## [v8.57.2](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8572-2026-03-23) ##### 🩹 Fixes - **eslint-plugin:** \[prefer-readonly-parameter-types] preserve type alias infomation ([#11954](typescript-eslint/typescript-eslint#11954)) - **eslint-plugin:** \[no-useless-default-assignment] skip reporting false positives for unresolved type parameters ([#12127](typescript-eslint/typescript-eslint#12127)) - **eslint-plugin:** \[no-unsafe-return] false positive on unwrapping generic ([#12125](typescript-eslint/typescript-eslint#12125)) - **eslint-plugin:** \[no-restricted-types] flag banned generics in extends or implements ([#12120](typescript-eslint/typescript-eslint#12120)) - **eslint-plugin:** \[array-type] ignore Array and ReadonlyArray without type arguments ([#11971](typescript-eslint/typescript-eslint#11971)) - **eslint-plugin:** \[prefer-optional-chain] remove dangling closing parenthesis ([#11865](typescript-eslint/typescript-eslint#11865)) ##### ❤️ Thank You - Kirk Waiblinger [@kirkwaiblinger](https://github.com/kirkwaiblinger) - Konv Suu - mdm317 - Newton Yuan [@NewtonYuan](https://github.com/NewtonYuan) - SungHyun627 [@SungHyun627](https://github.com/SungHyun627) - Tamashoo [@Tamashoo](https://github.com/Tamashoo) See [GitHub Releases](https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.57.2) for more information. You can read about our [versioning strategy](https://typescript-eslint.io/users/versioning) and [releases](https://typescript-eslint.io/users/releases) on our website. ## [v8.57.1](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8571-2026-03-16) ##### 🩹 Fixes - **eslint-plugin:** \[prefer-optional-chain] no report for property on intersection type ([#12126](typescript-eslint/typescript-eslint#12126)) ##### ❤️ Thank You - Newton Yuan [@NewtonYuan](https://github.com/NewtonYuan) See [GitHub Releases](https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.57.1) for more information. You can read about our [versioning strategy](https://typescript-eslint.io/users/versioning) and [releases](https://typescript-eslint.io/users/releases) on our website. ## [v8.57.0](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8570-2026-03-09) ##### 🚀 Features - **eslint-plugin:** \[no-unnecessary-condition] allow literal loop conditions in for/do loops ([#12080](typescript-eslint/typescript-eslint#12080)) ##### 🩹 Fixes - **eslint-plugin:** \[no-base-to-string] fix false positive for toString with overloads ([#12089](typescript-eslint/typescript-eslint#12089)) - **eslint-plugin:** \[prefer-promise-reject-errors] add allow `TypeOrValueSpecifier` to prefer-promise-reject-errors ([#12094](typescript-eslint/typescript-eslint#12094)) - **typescript-estree:** if the template literal is tagged and the text has an invalid escape, `cooked` will be `null` ([#11355](typescript-eslint/typescript-eslint#11355)) - **eslint-plugin:** guard against negative paramIndex in no-useless-default-assignment ([#12077](typescript-eslint/typescript-eslint#12077)) - **eslint-plugin:** handle statically analyzable computed keys in prefer-readonly ([#12079](typescript-eslint/typescript-eslint#12079)) - **eslint-plugin:** \[strict-void-return] false positives with overloads ([#12055](typescript-eslint/typescript-eslint#12055)) ##### ❤️ Thank You - Brad Zacher [@bradzacher](https://github.com/bradzacher) - Brian Schlenker [@bschlenk](https://github.com/bschlenk) - Evyatar Daud [@StyleShit](https://github.com/StyleShit) - James Henry [@JamesHenry](https://github.com/JamesHenry) - Josh Goldberg - Kirk Waiblinger [@kirkwaiblinger](https://github.com/kirkwaiblinger) - Moses Odutusin [@thebolarin](https://github.com/thebolarin) - Newton Yuan [@NewtonYuan](https://github.com/NewtonYuan) - SungHyun627 [@SungHyun627](https://github.com/SungHyun627) - Younsang Na [@nayounsang](https://github.com/nayounsang) See [GitHub Releases](https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.57.0) for more information. You can read about our [versioning strategy](https://typescript-eslint.io/users/versioning) and [releases](https://typescript-eslint.io/users/releases) on our website. ## [v8.56.1](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8561-2026-02-23) This was a version bump only for eslint-plugin to align it with other projects, there were no code changes. See [GitHub Releases](https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.56.1) for more information. You can read about our [versioning strategy](https://typescript-eslint.io/users/versioning) and [releases](https://typescript-eslint.io/users/releases) on our website.

PR Checklist
Overview
Fixes a false positive in
@typescript-eslint/no-extraneous-classfor classes that only declare an indexsignature.
The rule previously treated
TSIndexSignatureas if it didn't count as an instance member, which left the classcategorized as "only static" and reported
Unexpected class with only static properties.This change treats
TSIndexSignatureas a non-static class member and adds a regression test covering: