Vetur: fomatter problem to insert space before function parenthesis

Created on 19 Oct 2017  路  3Comments  路  Source: vuejs/vetur

Info

Problem

My config can't work in setting.json

"vetur.format.js.InsertSpaceBeforeFunctionParenthesis": true

Reproducible Case

After updating only the config as below I can use , can't I?

"vetur.format.defaultFormatter.js": "prettier"

But I want to insert space before function parenthesis, so what can I do?

question

Most helpful comment

You can change the defaultFormatter to vscode-typescript.

All 3 comments

You can change the defaultFormatter to vscode-typescript.

Thanks I have tried it, but It doesn't work. I also try to add this line

"typescript.format.insertSpaceBeforeFunctionParenthesis": true

There is a bug that the embedded formatter recognize lang="ts" blocks as js. I'll fix it soon. Meanwhile, you can set javascript.format.insertSpaceBeforeFunctionParenthesis": true.

This is item 1 in https://github.com/vuejs/vetur/issues/476 so I'll track it over there. Thanks.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AnnAngela picture AnnAngela  路  3Comments

pdanpdan picture pdanpdan  路  3Comments

octref picture octref  路  3Comments

thibautguedou3 picture thibautguedou3  路  3Comments

sacki5 picture sacki5  路  3Comments