bencodezen / vue-enterprise-boilerplate

An ever-evolving, very opinionated architecture and dev environment for new Vue SPA projects using Vue CLI.
7.78k stars 1.32k forks source link

Update Vetur config in settings.json #146

Closed pingren closed 5 years ago

pingren commented 5 years ago

Formatting is not working automatically when saving a .vue file. (Vetur 0.18.1)

Running Format Document manually, VSCode will ask user to pick the formatter

shot

It seems like VSCode won't use prettier as the default formatter.

Vetur support vetur.format.enable since 0.17.1.

Changing it to false will solve this issue.

Setting below is also helpful, VSCode March 2019 (version 1.33) required

  "[vue]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode"
  }
chrisvfritz commented 5 years ago

Thanks!