我这里正在抓狂,真的是毛都要拔光了。我使用的是Mac上的VSCode 1.6.0和Typescript 2.0.2版,但我也试过2.0.0版,无论是以es5、es6为目标,还是有没有使用commonjs模块化方案,我都没法在本地项目文件或node_modules文件夹中获得智能提示。我甚至将node_modules中的typescript文件安装到我的typings文件夹中,但还是无法正常工作。唯一能得到的智能提示只有我全局安装的typings。
{
"compilerOptions": {
"target": "es6",
"sourceMap": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"allowSyntheticDefaultImports": true,
"moduleResolution": "node"
},
"exclude": [
"node_modules"
]
}