-
安装插件Path Intellisense
-
在setting.json添加
{
"path-intellisense.mappings": {
"@": "${workspaceRoot}/src"
}
}
- 在package.json 添加jsconfig.json
{
"compilerOptions": {
"target": "ES6",
"module": "commonjs",
"allowSyntheticDefaultImports": true,
"baseUrl": "./",
"paths": {
"@/*": ["src/*"]
}
},
"exclude": [
"node_modules"
]
}
网友评论