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-estree): only call watch callback on new files #367



None yet
2 participants
Copy link

commented Mar 19, 2019

Addressing #243

Currently we are creating a new ts.Program for every subsequent file linted after the first in a given run with the project object given.

Here we cut down the number of times this happens by ensuring we only tell the TS API that a file has changed when we lint a file for a second time (thereby implying a --fix mode or "watch" mode).

@uniqueiniquity uniqueiniquity requested a review from JamesHenry Mar 19, 2019


This comment has been minimized.

Copy link

commented Mar 19, 2019

Codecov Report

Merging #367 into master will decrease coverage by 0.03%.
The diff coverage is 100%.

@@            Coverage Diff            @@
##           master    #367      +/-   ##
- Coverage   97.24%   97.2%   -0.04%     
  Files          67      67              
  Lines        2357    2360       +3     
  Branches      336     337       +1     
+ Hits         2292    2294       +2     
  Misses         44      44              
- Partials       21      22       +1
Impacted Files Coverage Δ
packages/typescript-estree/src/tsconfig-parser.ts 91.8% <100%> (-1.31%) ⬇️

@JamesHenry JamesHenry merged commit 0ef07c4 into typescript-eslint:master Mar 19, 2019

3 checks passed

Semantic Pull Request ready to be squashed
codecov/patch 100% of diff hit (target 90%)
codecov/project Absolute coverage decreased by -0.03% but relative coverage increased by +2.75% compared to 3b28cac

@uniqueiniquity uniqueiniquity deleted the uniqueiniquity:reduceWatchCallbacks branch Mar 19, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.