Vscode format es6 import {} automatic line wrapping, all with objects {} will automatically wrap!

vscode format es6 import {} automatic line wrapping, all with object {} will automatically wrap!

import { Message } from "element-ui"
// 
import {
  Message
} from "element-ui"

and

next({ path: "/" })
// 
next({
 path: "/"
})

I just want to show it on the same line, but I can"t.
found a circle in the configuration of vscode, searched the Internet for a long time, but still had no results, and my heart was tired.
I believe that many friends encounter this problem. Many people turn off automatic formatting, but this is not good either. In some places, automatic formatting is still needed.


Google has found the answer, after testing ok

vscode settings


1.eslint<br>2.vetur<br>3.eslint.eslintrc.jselisnt4ctrl+s<br>4.

"editor.formatOnSave": false,
"vetur.format.defaultFormatter.html": "js-beautify-html",
"eslint.autoFixOnSave": true,
"eslint.validate": [
    "javascript",
    "javascriptreact",
    "html",
    {
        "language": "vue",
        "autoFix": true
    },
    {
        "language": "typescript",
        "autoFix": true
    },
    {
        "language": "typescriptreact",
        "autoFix": true
    }
],
Menu