VSCode single to double quote automatic replace
For projects that use .editorconfig
file by default. The formatter will ignore the rules in the settings and use the rules in .editorconfig
, then you can either:
- Remove
.editorconfig
file, and use your VSCode settings. - Add
quote_type = single
to the.editorconfig
file regarding your file type. You can also setquote_type
value todouble
orauto
.
Well, like the guy (@user2982122) mentioned but instead of File go to Code -> Preferences -> Settings, then look for Quote, select Prettier and check both boxes
I dont have prettier
extension installed, but after reading the possible duplicate answer I've added from scratch in my User Setting (UserSetting.json
, Ctrl+, shortcut):
"prettier.singleQuote": true
A part a green warning (Unknown configuration setting
) the single quotes are no more replaced.
I suspect that the prettier extension is not visible but is embedded inside the Vetur extension.