我的 jsconfig.json 文件报告了一个问题:
File 'c:/.../node_modules/source-map/source-map' not found.
The file is in the program because:
Root file specified for compilation
它总是报告两次,并指向文件中的第一个 {
。
这是我的 jsconfig.json
{
"compilerOptions": {
"module": "commonjs",
"target": "es6",
"baseUrl": ".",
"paths": {
"@/*": ["src/*"],
}
},
"include": [
"src/**/*"
],
"exclude": ["node_modules"]
}
当我重新加载 VSCode 时,它消失了几分钟,然后在使用 VSCode 时重新出现。
将
"noEmit": true
添加到compilerOptions
and 重新加载 VSCode 似乎对我有用。