Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix(eslint-plugin): [consistent-indexed-object-style] check for indirect circular types in aliased mapped types #11177

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

Merged
merged 7 commits into from
May 12, 2025

Conversation

ronami
Copy link
Member

@ronami ronami commented May 5, 2025

PR Checklist

Overview

This PR addresses #11121 and changes the current circular check for aliased mapped types to use isDeeplyReferencingType which also checks for indirect circular types.

Edit: Once #11180 is merged, codecov should be green (unable to add the test currently since it breaks syntax).

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @ronami!

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.

Copy link

netlify bot commented May 5, 2025

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit ad40be8
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/6821e93ca03bc40008ab1dd2
😎 Deploy Preview https://deploy-preview-11177--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 93 (🔴 down 6 from production)
Accessibility: 100 (no change from production)
Best Practices: 100 (no change from production)
SEO: 98 (no change from production)
PWA: 80 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

nx-cloud bot commented May 5, 2025

View your CI Pipeline Execution ↗ for commit ad40be8.

Command Status Duration Result
nx typecheck ast-spec ✅ Succeeded <1s View ↗
nx run-many --target=build --exclude website --... ✅ Succeeded 15s View ↗
nx run-many --target=clean ✅ Succeeded 10s View ↗

☁️ Nx Cloud last updated this comment at 2025-05-12 12:40:37 UTC

Copy link

codecov bot commented May 5, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.92%. Comparing base (b2be3dc) to head (ad40be8).
Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #11177   +/-   ##
=======================================
  Coverage   90.92%   90.92%           
=======================================
  Files         499      499           
  Lines       50841    50845    +4     
  Branches     8380     8384    +4     
=======================================
+ Hits        46227    46231    +4     
  Misses       4599     4599           
  Partials       15       15           
Flag Coverage Δ
unittest 90.92% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...lugin/src/rules/consistent-indexed-object-style.ts 99.32% <100.00%> (+<0.01%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ronami
Copy link
Member Author

ronami commented May 6, 2025

Once #11180 is merged, codecov should be green (unable to add the test currently since it breaks syntax).

@ronami ronami marked this pull request as ready for review May 6, 2025 15:07
Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! +1 to continuing to use isDeeplyReferencingType more.

I'll try to get this merged up now for the weekly release later today.

@JoshuaKGoldberg JoshuaKGoldberg added the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label May 12, 2025
@JoshuaKGoldberg JoshuaKGoldberg merged commit f8db925 into typescript-eslint:main May 12, 2025
53 checks passed
@ronami ronami deleted the circular-mapped-types branch May 12, 2025 20:38
renovate bot added a commit to andrei-picus-tink/auto-renovate that referenced this pull request May 17, 2025
| datasource | package                          | from   | to     |
| ---------- | -------------------------------- | ------ | ------ |
| npm        | @typescript-eslint/eslint-plugin | 8.31.0 | 8.32.1 |
| npm        | @typescript-eslint/parser        | 8.31.0 | 8.32.1 |


## [v8.32.1](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8321-2025-05-12)

##### 🩹 Fixes

-   **eslint-plugin:** \[consistent-indexed-object-style] check for indirect circular types in aliased mapped types ([#11177](typescript-eslint/typescript-eslint#11177))
-   **eslint-plugin:** \[consistent-indexed-object-style] adjust auto-fixer to generate valid syntax for `TSMappedType` with no type annotation ([#11180](typescript-eslint/typescript-eslint#11180))
-   **eslint-plugin:** \[no-deprecated] support computed member access ([#10867](typescript-eslint/typescript-eslint#10867))
-   **eslint-plugin:** \[no-unnecessary-type-conversion] shouldn't have fixable property ([#11194](typescript-eslint/typescript-eslint#11194))

##### ❤️ Thank You

-   Azat S. [@azat-io](https://github.com/azat-io)
-   Dima Barabash [@dbarabashh](https://github.com/dbarabashh)
-   Ronen Amiel

You can read about our [versioning strategy](https://main--typescript-eslint.netlify.app/users/versioning) and [releases](https://main--typescript-eslint.netlify.app/users/releases) on our website.


## [v8.32.0](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8320-2025-05-05)

##### 🚀 Features

-   **eslint-plugin:** \[only-throw-error] add option `allowRethrowing` ([#11075](typescript-eslint/typescript-eslint#11075))
-   **eslint-plugin:** \[no-unnecessary-type-conversion] add rule ([#10182](typescript-eslint/typescript-eslint#10182))

##### 🩹 Fixes

-   **eslint-plugin:** \[prefer-nullish-coalescing] fix parenthesization bug in suggestion ([#11098](typescript-eslint/typescript-eslint#11098))
-   **eslint-plugin:** \[unified-signatures] exempt `this` from optional parameter overload check ([#11005](typescript-eslint/typescript-eslint#11005))
-   **eslint-plugin:** \[no-unnecessary-type-parameters] should parenthesize type in suggestion fixer if necessary ([#10907](typescript-eslint/typescript-eslint#10907))

##### ❤️ Thank You

-   Andy Edwards
-   Kirk Waiblinger [@kirkwaiblinger](https://github.com/kirkwaiblinger)
-   mdm317
-   Sasha Kondrashov
-   Yukihiro Hasegawa [@y-hsgw](https://github.com/y-hsgw)

You can read about our [versioning strategy](https://main--typescript-eslint.netlify.app/users/versioning) and [releases](https://main--typescript-eslint.netlify.app/users/releases) on our website.


## [v8.31.1](https://github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/eslint-plugin/CHANGELOG.md#8311-2025-04-28)

##### 🩹 Fixes

-   **eslint-plugin:** \[no-unnecessary-condition] downgrade fix to suggestion ([#11081](typescript-eslint/typescript-eslint#11081))

##### ❤️ Thank You

-   Kirk Waiblinger [@kirkwaiblinger](https://github.com/kirkwaiblinger)

You can read about our [versioning strategy](https://main--typescript-eslint.netlify.app/users/versioning) and [releases](https://main--typescript-eslint.netlify.app/users/releases) on our website.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge
Projects
None yet
2 participants