Typescript VSCode-TSLint错误ENOTDIR无效cwd
我将VSCode与TSLint(v5.11.0)一起使用 我将VSCode设置为:Typescript VSCode-TSLint错误ENOTDIR无效cwd,typescript,visual-studio-code,tslint,Typescript,Visual Studio Code,Tslint,我将VSCode与TSLint(v5.11.0)一起使用 我将VSCode设置为: “tslint.autoFixOnSave”:true 但是,每当我打开任何ts文件时,输出上都会出现以下ts错误: [Info - 14:52:31] vscode-tslint: Status is OK [Info - 14:52:31] vscode-tslint: Cannot read tslint configuration - 'ENOTDIR invalid cwd /Users/batma
“tslint.autoFixOnSave”:true
但是,每当我打开任何ts文件时,输出上都会出现以下ts错误:
[Info - 14:52:31] vscode-tslint: Status is OK
[Info - 14:52:31] vscode-tslint: Cannot read tslint configuration - 'ENOTDIR invalid cwd /Users/batman/project/Command.ts'
由于此错误,vscode不会自动修复我的tslint.json文件中的TS问题
这不仅仅是一个文件,而是我打开的任何类型脚本文件。请让我知道如何解决这个问题
谢谢。看起来您没有
tsconfig.json
文件
如果您确实有一个,它就不在项目的根文件夹(也称为cwd)中
请参阅文档:我确实在我的目录根目录下有一个有效的
tsconfig.json
和tslint.json
文件,但我仍然得到错误。。。在我看来,vscode tslint
假设cwd不正确vscode tslint:cannotreadtslint配置-'enotdirinvalid cwd/Users/mbirsan/workspace/WSNAME/src/ProjectName/src/pages/home/home.tsx'