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(typescript-eslint): apply ignores to all extended configs passed to config helper function #8567

Merged
merged 1 commit into from Feb 27, 2024

Conversation

auvred
Copy link
Member

@auvred auvred commented Feb 27, 2024

PR Checklist

Overview

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @auvred!

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 Feb 27, 2024

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit 1301167
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/65de06a1db9b9d0008714af8
😎 Deploy Preview https://deploy-preview-8567--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: 96 (🔴 down 3 from production)
Accessibility: 100 (no change from production)
Best Practices: 92 (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.

Comment on lines +95 to +96
...(config.files && { files: config.files }),
...(config.ignores && { ignores: config.ignores }),
Copy link
Member Author

Choose a reason for hiding this comment

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

ignores will overwrite ignores from the extended config. I'm not sure if this is the desired behavior, but so far I've made it to match the behavior of files. Any thoughts on this?

Copy link
Member

Choose a reason for hiding this comment

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

I think overriding is correct.
Any local config should always override the extended config

Copy link

codecov bot commented Feb 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.12%. Comparing base (4bc6944) to head (1301167).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8567      +/-   ##
==========================================
- Coverage   87.84%   87.12%   -0.72%     
==========================================
  Files         397      251     -146     
  Lines       13844    12268    -1576     
  Branches     4073     3868     -205     
==========================================
- Hits        12161    10689    -1472     
+ Misses       1381     1307      -74     
+ Partials      302      272      -30     
Flag Coverage Δ
unittest 87.12% <100.00%> (-0.72%) ⬇️

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

Files Coverage Δ
packages/typescript-eslint/src/config-helper.ts 100.00% <100.00%> (+90.00%) ⬆️

... and 146 files with indirect coverage changes

Copy link
Member

@bradzacher bradzacher left a comment

Choose a reason for hiding this comment

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

Comment on lines +95 to +96
...(config.files && { files: config.files }),
...(config.ignores && { ignores: config.ignores }),
Copy link
Member

Choose a reason for hiding this comment

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

I think overriding is correct.
Any local config should always override the extended config

@bradzacher bradzacher merged commit 156c528 into typescript-eslint:main Feb 27, 2024
58 of 60 checks passed
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: config function from typescript-eslint doesn't use ignores when extends is provided.
2 participants