HTML-CSS-JS Prettify:格式化代码插件
使用此插件需要安装node.js;并牢记安装路径,全选右键选择格式化后会跳出node_path配置,将路径设置为如下代码就可以了。
{
"node_path": {
"windows": "D:\\Program Files\\nodejs\\node.exe",
"linux": "/usr/bin/nodejs",
"osx": "/usr/local/bin/node"
},
"format_on_save": false,
"format_selection_only": true,
"print_diagnostics": true
}
注意的是:路径需要用\转义