dojo / cli-build-webpack

🚀 **DEPRECATED** Dojo 2 - cli command for building applications
http://dojo.io
Other
4 stars 19 forks source link

TSLint loader has no access to tsconfig.json #258

Closed sindilevich closed 6 years ago

sindilevich commented 6 years ago

Semantic TSLint rules use the compiler's program APIs to inspect static types and validate code patterns.

In order for TSLint to run its semantic rules, when using the CLI, use the --project flag and specify your tsconfig.json to enable rules that work with the type checker. See https://palantir.github.io/tslint/usage/type-checking.

However, the current implementation passes the tslint.json file to the tslint-loader, as its tsConfigFile parameter. https://github.com/dojo/cli-build-webpack/blob/c3329497523bf8ead02a7b6ce1242262fea7c6a8/src/webpack.config.ts#L326-L328

Whereas this code suggest a tsconfig.json file should be passed by this option instead, while the TSLint configuration comes from elsewhere at Webpack.