jonaskello / tslint-immutable

TSLint rules to disable mutation in TypeScript.
MIT License
417 stars 14 forks source link

update `no-throw` to not allow Promise.reject() #116

Closed sbdchd closed 5 years ago

sbdchd commented 5 years ago

We currently ban throw inside async functions and Promise.reject() is another form of async throw.

rel: https://github.com/jonaskello/tslint-immutable/issues/115

codecov[bot] commented 5 years ago

Codecov Report

Merging #116 into master will not change coverage. The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #116   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files          15     15           
  Lines         353    360    +7     
  Branches      148    152    +4     
=====================================
+ Hits          353    360    +7
Impacted Files Coverage Δ
src/noThrowRule.ts 100% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update eedc324...72bf09d. Read the comment docs.

jonaskello commented 5 years ago

Nice work! :-)

I think we should include a description of this new feature in the readme under the no-throw rule section. Could you update the readme too in this PR?

jonaskello commented 5 years ago

Thanks!

jonaskello commented 5 years ago

Released in 5.2.0.