Skip to content
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

Replace deprecated prettier eslint integration with the vscode plugin #5822

Merged
merged 2 commits into from
Feb 23, 2023

Conversation

keianhzo
Copy link
Contributor

@keianhzo keianhzo commented Nov 29, 2022

The prettier eslint integration has been deprecated so in VSCode we are falling back to the default formatter on save that doesn't follow the same rules as the ones defined in eslintrc.

This only affect people using VSCode.

Read more here: prettier/prettier-vscode#870

// Use 'prettier-eslint' instead of 'prettier'. Other settings will only be fallbacks in case they could not be inferred from eslint rules.
"prettier.eslintIntegration": true,
// Using the prettier-vscode plugin as the old eslint integration has been deprecated. More here: https://github.com/prettier/prettier-vscode/issues/870
"editor.defaultFormatter": "esbenp.prettier-vscode",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this configuration specifically for vs code users?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe everything under the .vscode/ folder is only applied by VSCode (maybe also some compatible forks?) But it should not affect other editors unless they purposefully read that file.

Copy link
Contributor

@nickgrato nickgrato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, I think the only thing ( and this could be a big change ) that I would change is the actual prettier file that this references.

I have these in Subscriptions and Marketing project, some of these might be default and unnecessary.

{
  "singleQuote": true,
  "jsxSingleQuote": false,
  "tabWidth": 2,
  "semi": true
}

Been a heavy adopter of single quotes in Javascript and double quotes in HMTL/JSX however.

@keianhzo keianhzo merged commit 8a08595 into master Feb 23, 2023
@keianhzo keianhzo deleted the vscode-eslint branch February 23, 2023 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants