VSCode格式化代码后,设置代码不自动换行
1、ctrl +, 打开设置;
2、点击工作区,点击右上角 打开设置(json)

3、输入选择代码,并保存;

内容代码如下:
{ "vetur.format.defaultFormatter.html": "js-beautify-html", "vetur.format.defaultFormatter.js": "vscode-typescript", "vetur.format.defaultFormatterOptions": { "js-beautify-html": { "wrap_line_length": 240, "wrap_attributes": "auto", "end_with_newline": false }, "prettyhtml": { "printWidth": 100, "singleQuote": false, "wrapAttributes": false, "sortAttributes": false } }, }

浙公网安备 33010602011771号