【发布时间】:2019-05-26 18:47:30
【问题描述】:
我的 vscode 配备了 vetur 插件。自定义配置如下:
"vetur.format.options.tabSize": 2,
"vetur.format.defaultFormatterOptions": {
"js-beautify-html": {
"wrap_attributes": "auto"
},
"prettyhtml": {
"printWidth": 10000,
"singleQuote": false,
"wrapAttributes": false,
"sortAttributes": false
}
},
"vetur.format.defaultFormatter.html": "js-beautify-html"
其他为默认配置
vetur版本号为0.14.4,vscode版本号为1.30.1。
用vuejs编程的时候大概写了300多行。按下格式化快捷键后,光标不在格式化的地方。它位于</script> 标签的前面。这是非常痛苦的。现在你必须每次都记住它。格式化的地方的行数,然后自己跳回去
【问题讨论】:
标签: vue.js visual-studio-code prettier vetur