New release of Prettier breaks formatting
See original GitHub issueTitle. They seem to have added support for Vue single file components upstream: https://github.com/prettier/prettier-vscode/issues/325
I’m now getting “Unexpected token” Prettier errors in HTML comments and Vue attributes (like @change
) despite having HTML formatting disabled.
Issue Analytics
- State:
- Created 6 years ago
- Comments:12 (7 by maintainers)
Top Results From Across the Web
Options - Prettier
To have Prettier wrap prose to the print width, change this option to "always". If you want Prettier to force all prose blocks...
Read more >Rationale - Prettier
Prettier collapses multiple blank lines into a single blank line. Empty lines at the start and end of blocks (and whole files) are...
Read more >Prettier 2.6: new singleAttributePerLine option and new ...
This release includes a new singleAttributePerLine option. This is an option to print only one attribute per line in Vue SFC templates, ...
Read more >Prettier 2.1: new --embedded-language-formatting option and ...
This release adds a new `--embedded-language-formatting` option, supports new JavaScript/TypeScript features, and includes many bug fixes ...
Read more >Prettier 2.3. In which assignments are consistent, short keys ...
This release focuses on fixing long-standing issues in the JavaScript printer. Be warned that, unfortunately, reformatting a project with ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Huh. I just tested removing the
parser
setting and it’s now working. Leaving this issue open in case that should not be the case. (Indeed setting parser to Babylon worked before the Prettier update)Alternatively, you can disable prettier in Vue.
https://github.com/prettier/prettier-vscode#prettierdisablelanguages-default-