goldbergyoni / goldbergyoni/nodebestpractices
Add matching ESLint rules
- Dominant language
- Dockerfile
- Stars
- 106k
- Forks
- 10.7k
- PR merge metrics
- No merged PRs in 30d
Description
There are serval best practices that have matching ESLint rules (like #892)
I opened this issue to keep track of those rules and discuss ideas about adding them
| Best Practice | ESLint Rule | Note | Matching PR |
| ------------- | ------------| ----- | ------ |
| [**3.3** Start a codeblocks curly braces on the same line](https://github.com/goldbergyoni/nodebestpractices#-33-start-a-codeblocks-curly-braces-on-the-same-line) | [`brace-style`](https://eslint.org/docs/2.0.0/rules/brace-style) - `1tbs` | `1tbs` is currently the default value for this rule | |
| [**3.7** Prefer const over let. Ditch the var](https://github.com/goldbergyoni/nodebestpractices#-37-prefer-const-over-let-ditch-the-var) | [`no-var`](https://eslint.org/docs/rules/no-var) | I think we should add warning for [this](https://eslint.org/docs/rules/no-var#when-not-to-use-it) | |
| [**3.10** Use the === operator](https://github.com/goldbergyoni/nodebestpractices#-310-use-the--operator) | [`eqeqeq`](https://eslint.org/docs/rules/eqeqeq) | |
| [**3.5** Name your functions](https://github.com/goldbergyoni/nodebestpractices#-35-name-your-functions) | [`func-names`](https://eslint.org/docs/rules/func-names) - `always` | `always` is currently the default value for this rule | |
What do you think of adding a badge with the matching ESLint rule?
If we do so where should we add some comment about the specific rule (like in #892 and the limitation of the rule)
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.