-
-
Notifications
You must be signed in to change notification settings - Fork 458
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The vscode extension is inconsistent with the default value of the prettier configuration file #3453
Comments
I had exactly this problem - it's becuase the version of prettier itself bundled inside the vs code extension is an old version (2.8) which has a different default value for the trailing comma parameter as suggested somewhere in the documentation, if you |
@timrobinson33 I was running into this issue even when prettier 3 was locally installed and I had pointed the extension at that executable. I'm pretty sure VSCode settings defaults are static anyway, and it would be impossible to change them based upon the locally installed prettier. It baffles me that anyone benefits from being able to configure prettier format in their VSCode settings. |
Hmm I'm not sure what you were seeing. the documentation says: "Should prettier not be installed locally with your project's dependencies or globally on the machine, the version of prettier that is bundled with the extension will be used." and also: "Prettier's preview version 3 is supported as of version 9.12.0. It is not included in the extension by default, but can be used by installing locally in your project" and this is definitely what happened for me. TBH though there are so many different ways to configure these tools and what with prettier, eslint, tsconfig, package.json etc, not to mention all the vs code settings files, I struggle to figure out what's going on most of the time :-) |
Yeah the extension can use prettier 3 but that doesn't mean it will change the default format settings in the extension. Try it in a project that doesn't declare its own format settings, you will see |
I found that the default configuration of the prettier vscode extension is inconsistent with the prettier configuration file.
For example, the default configuration of prettier vscode extended
trailingComma
ises5
, while the default configuration of prettier configuration file isall
.The text was updated successfully, but these errors were encountered: