-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
chore(*): Enable comma-dangle #271
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
Conversation
@@ -7,6 +7,7 @@ | |||
}, | |||
"extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended"], | |||
"rules": { | |||
"comma-dangle": ["error", "always-multiline"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need eslint rule for this? we are using prettier
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the lint rule gives you in-editor warnings when you're writing code (helps in case you don't have format on save turned on).
will also give a better warning in the CI logs. (the prettier check will just say the file failed formatting, whereas the eslint check will tell you the actual problem)
i'm unsure if i like this Pros:
Cons:
i don't have strong opinion on code style |
I write objects in one line and let Prettier format things for me! |
Pros:
It's covered by eslint fixers and by prettier.
|
This comment has been minimized.
This comment has been minimized.
# Conflicts: # packages/eslint-plugin/src/rules/prefer-namespace-keyword.ts # packages/eslint-plugin/tests/rules/promise-function-async.test.ts # packages/typescript-estree/src/convert.ts # packages/typescript-estree/src/node-utils.ts # tests/integration/utils/generate-package-json.js
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have definitely read every single line
As per the discussion on slack.
Enable
comma-dangle
eslint rule + prettier config.Good for two reasons:
Steps to create this PR:
yarn format
No other code was manually touched in the making of this PR.