plantain-00 / type-coverage

A CLI tool to check type coverage for typescript code
MIT License
1.21k stars 43 forks source link

typing from monorepo libs should not count #42

Closed filosfino closed 4 years ago

filosfino commented 4 years ago

Version(if relevant): 2.0.1

Environment(if relevant):

Code(if relevant):

# arkie monorepo
$ yarn build:cache
$ yarn workspace @arkie/coloring-engine coverage --detail

Expected:

typing from other monorepo libs should not be counted (maybe when skipLibCheck is set in tsconfig.json?)

Actual:

image

plantain-00 commented 4 years ago

v2.4.1 should fix this.

filosfino commented 4 years ago

Would it be better to follow tsconfig.json files/includes setting?

plantain-00 commented 4 years ago

For example:

// a.ts
import './b'
// b.ts

If files or include is ["./a.ts"], b.ts will be compiled by typescript, so if files or include is followed by type-coverage, then b.ts's any will never report.

filosfino commented 4 years ago

yep that's right, thanks :)