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): [consistent-type-assertions] always allow const assertions #1713

Merged
merged 3 commits into from Apr 12, 2020

Conversation

garyking
Copy link
Contributor

@garyking garyking commented Mar 9, 2020

The consistent-type-assertions rule should always allow as const, as it is beneficial, per the official TypeScript docs.

Closes #992.

@garyking garyking changed the title consistent-type-assertions: Always allow the beneficial as const feat(eslint-plugin): consistent-type-assertions: Always allow the beneficial as const Mar 9, 2020
@bradzacher bradzacher added the enhancement New feature or request label Mar 9, 2020
@garyking
Copy link
Contributor Author

garyking commented Apr 4, 2020

@bradzacher Anything I can do to help move this PR along? 🙂

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.

ezpz thanks for this

@codecov
Copy link

codecov bot commented Apr 12, 2020

Codecov Report

Merging #1713 into master will decrease coverage by 0.00%.
The diff coverage is 85.71%.

@@            Coverage Diff             @@
##           master    #1713      +/-   ##
==========================================
- Coverage   94.49%   94.48%   -0.01%     
==========================================
  Files         162      162              
  Lines        7481     7487       +6     
  Branches     2143     2146       +3     
==========================================
+ Hits         7069     7074       +5     
  Misses        178      178              
- Partials      234      235       +1     
Flag Coverage Δ
#unittest 94.48% <85.71%> (-0.01%) ⬇️
Impacted Files Coverage Δ
...int-plugin/src/rules/consistent-type-assertions.ts 86.48% <85.71%> (-0.62%) ⬇️

@bradzacher bradzacher changed the title feat(eslint-plugin): consistent-type-assertions: Always allow the beneficial as const feat(eslint-plugin): [consistent-type-assertions] always allow const assertions Apr 12, 2020
@bradzacher bradzacher merged commit af2c00d into typescript-eslint:master Apr 12, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[consistent-type-assertions] Disable check as const if assertionStyle: never
2 participants