在setting.json中把下面的配置项拷上去
"vetur.format.defaultFormatterOptions": {
"js-beautify-html": {
"wrap_line_length": 900, // 数值越大,一行放的属性越多
"wrap_attributes": "auto",
"end_with_newline": false
},
"prettyhtml": {
"printWidth": 100,
"singleQuote": false,
"wrapAttributes": false,
"sortAttributes": false
}
},
"vetur.format.defaultFormatter.html": "js-beautify-html",
"vetur.format.defaultFormatter.js": "vscode-typescript"
原文:https://www.cnblogs.com/zoo-x/p/14601074.html