Why Prettier does not format code in VSCODE?

后端 未结 18 780
失恋的感觉
失恋的感觉 2020-12-07 18:39

In my Nuxt application where ESlint and Prettier are installed and enabled, I switched to Visual Studio Code editor.

When I open a .vue file and pre

18条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-07 19:03

    How I've sorted it after having super huge frustrations with Prettier stopping working in VSCode.

    1. Select VS Code -> View -> Command Palette, and type: Format Document With
    2. Then Configure Default Formatter... and then choose Prettier - Code formatter.

    This sorted the problem for me magically.

    Depending on your case this might help you...

提交回复
热议问题