Skip to content
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

fix(eslint-plugin): [no-unnecessary-condition] handle index signature type #5912

Merged
merged 1 commit into from Nov 15, 2022

Conversation

yeonjuan
Copy link
Contributor

@yeonjuan yeonjuan commented Nov 1, 2022

PR Checklist

Overview

Adds handling for type index signatures to nullable origin checking.

@nx-cloud
Copy link

nx-cloud bot commented Nov 1, 2022

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 4a0c9eb. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


Successfully ran 46 targets

Sent with 💌 from NxCloud.

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @yeonjuan!

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.

@netlify
Copy link

netlify bot commented Nov 1, 2022

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit 4a0c9eb
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/636150491630820008ff2938
😎 Deploy Preview https://deploy-preview-5912--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

@codecov
Copy link

codecov bot commented Nov 1, 2022

Codecov Report

Merging #5912 (4a0c9eb) into main (1f14c03) will decrease coverage by 0.03%.
The diff coverage is 100.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5912      +/-   ##
==========================================
- Coverage   91.35%   91.32%   -0.04%     
==========================================
  Files         365      365              
  Lines       12199    12214      +15     
  Branches     3560     3564       +4     
==========================================
+ Hits        11144    11154      +10     
- Misses        749      752       +3     
- Partials      306      308       +2     
Flag Coverage Δ
unittest 91.32% <100.00%> (-0.04%) ⬇️

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

Impacted Files Coverage Δ
...slint-plugin/src/rules/no-unnecessary-condition.ts 98.33% <100.00%> (+0.01%) ⬆️
...s/utils/src/eslint-utils/rule-tester/RuleTester.ts 85.54% <0.00%> (-4.46%) ⬇️
packages/utils/src/ts-eslint/RuleTester.ts 100.00% <0.00%> (ø)
.../eslint-plugin/src/rules/sort-type-constituents.ts 90.74% <0.00%> (ø)
.../src/rules/sort-type-union-intersection-members.ts 90.74% <0.00%> (ø)

@yeonjuan yeonjuan marked this pull request as ready for review November 2, 2022 03:42
@JoshuaKGoldberg JoshuaKGoldberg changed the title fix(eslint-plugin): [no-unnecessary-condition] handle mapped type fix(eslint-plugin): [no-unnecessary-condition] handle index signature type Nov 15, 2022
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.

LGTM, thanks @yeonjuan! 🚀

@JoshuaKGoldberg JoshuaKGoldberg enabled auto-merge (squash) November 15, 2022 16:49
@JoshuaKGoldberg JoshuaKGoldberg merged commit 5baad08 into typescript-eslint:main Nov 15, 2022
40 checks passed
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[no-unnecessary-condition] Shows optional chaining on index signature type as unnecessary
2 participants