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

feat(eslint-plugin): add rule sort-type-union-intersection-members #2913

Merged
merged 1 commit into from Jan 4, 2021

Conversation

bradzacher
Copy link
Member

@bradzacher bradzacher commented Jan 3, 2021

Pretty straightforward.
For #2911 I was annoyed at having to remember to manually sort every union type.
And going forwards I'd like to validate that they're sorted.

Sorting is great because it makes it super simple to manually verify there's no duplicate types, and it reduces diff churn.

@bradzacher bradzacher added the enhancement: new plugin rule New rule request for eslint-plugin label Jan 3, 2021
@typescript-eslint
Copy link
Contributor

Thanks for the PR, @bradzacher!

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. As a thank you, your profile/company logo will be added to our main README which receives thousands of unique visitors per day.

@codecov
Copy link

codecov bot commented Jan 3, 2021

Codecov Report

Merging #2913 (fdd94d6) into master (4d69fbb) will decrease coverage by 0.00%.
The diff coverage is 92.30%.

@@            Coverage Diff             @@
##           master    #2913      +/-   ##
==========================================
- Coverage   92.76%   92.76%   -0.01%     
==========================================
  Files         310      311       +1     
  Lines       10395    10460      +65     
  Branches     2944     2957      +13     
==========================================
+ Hits         9643     9703      +60     
- Misses        347      348       +1     
- Partials      405      409       +4     
Flag Coverage Δ
unittest 92.76% <92.30%> (-0.01%) ⬇️

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

Impacted Files Coverage Δ
packages/eslint-plugin/src/configs/all.ts 100.00% <ø> (ø)
.../src/rules/sort-type-union-intersection-members.ts 92.30% <92.30%> (ø)

@bradzacher bradzacher force-pushed the union-intersection-sorting branch 2 times, most recently from c14ebb3 to ab8195c Compare January 3, 2021 20:33
@bradzacher bradzacher merged commit 9092c04 into master Jan 4, 2021
@bradzacher bradzacher deleted the union-intersection-sorting branch January 4, 2021 01:12
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 4, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement: new plugin rule New rule request for eslint-plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant