Multi-project configuration doesn't type check files not included in any project #724
Labels
bug
Something isn't working
has pr
there is a PR raised to close this
package: typescript-estree
Issues related to @typescript-eslint/typescript-estree
What code were you trying to parse?
What did you expect to happen?
No warnings
What actually happened?
A warning from
@typescript-eslint/restrict-plus-operands
rule.After a bit of debugging I found out that type checker returned
any
type for thevalue
node. It happened becauseproject
didn't contain a reference to package's tsconfig file, so this file was linted in a context of an inferred project.I've tried to reproduce it in an isolated environment and looks like it works correctly if there is only one project.
UPD: After reading source it makes sense that it can't do the same thing it does with a single config, but falling back to the same program used for non-type-checked rules should also make rules handle it like it does without any project specified - throw an error.
Versions
@typescript-eslint/typescript-estree
1.12.0
TypeScript
3.5.3
node
12.1.0
npm
6.9.0
The text was updated successfully, but these errors were encountered: